diff options
author | Jose A Ortega Ruiz <jao@gnu.org> | 2007-06-25 23:20:06 +0000 |
---|---|---|
committer | Jose A Ortega Ruiz <jao@gnu.org> | 2007-06-25 23:20:06 +0000 |
commit | d6b247e85f35583a0e10c5000a3f93063c4b807c (patch) | |
tree | 24f492adcf3bdc810a24b6cba1957a831f8bd0bb /mixguile/mixguile_cmd_dispatcher.c | |
parent | 33797e0618cb6318c299d2945903003a55e59e42 (diff) | |
download | mdk-d6b247e85f35583a0e10c5000a3f93063c4b807c.tar.gz mdk-d6b247e85f35583a0e10c5000a3f93063c4b807c.tar.bz2 |
GPL v3 notices
git-archimport-id: mdk@sv.gnu.org/mdk--devel--1--patch-43
Diffstat (limited to 'mixguile/mixguile_cmd_dispatcher.c')
-rw-r--r-- | mixguile/mixguile_cmd_dispatcher.c | 26 |
1 files changed, 12 insertions, 14 deletions
diff --git a/mixguile/mixguile_cmd_dispatcher.c b/mixguile/mixguile_cmd_dispatcher.c index 2cc243b..e5b9cce 100644 --- a/mixguile/mixguile_cmd_dispatcher.c +++ b/mixguile/mixguile_cmd_dispatcher.c @@ -1,24 +1,22 @@ /* -*-c-*- -------------- mixguile_cmd_dispatcher.c : * Implementation of the functions declared in mixguile_cmd_dispatcher.h * ------------------------------------------------------------------ - * Last change: Time-stamp: "01/08/22 02:29:34 jao" - * ------------------------------------------------------------------ - * Copyright (C) 2001 Free Software Foundation, Inc. - * + * Copyright (C) 2001, 2007 Free Software Foundation, Inc. + * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or + * the Free Software Foundation; either version 3 of the License, or * (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - * + * */ #include <stdio.h> @@ -53,7 +51,7 @@ static mix_vm_command_info_t commands_[] = { { SCMF_CMD, cmd_scmf_, N_("Eval Scheme file using Guile"), "scm PATH"}, {NULL} }; - + /* create/destroy cmd dispatcher */ mixguile_cmd_dispatcher_t * mixguile_cmd_dispatcher_new (mix_vm_cmd_dispatcher_t *dis) @@ -61,9 +59,9 @@ mixguile_cmd_dispatcher_new (mix_vm_cmd_dispatcher_t *dis) static gboolean REGISTERED = FALSE; mixguile_cmd_dispatcher_t *result = NULL; int k = 0; - + g_return_val_if_fail (dis != NULL, NULL); - + if (!REGISTERED) { register_scm_commands_ (DEFAULT_SCM_COMMANDS_); @@ -72,15 +70,15 @@ mixguile_cmd_dispatcher_new (mix_vm_cmd_dispatcher_t *dis) result = g_new (mixguile_cmd_dispatcher_t, 1); result->dispatcher = dis; - + while (commands_[k].name) { mix_vm_cmd_dispatcher_register_new (dis, commands_ + k); ++k; } - + register_cmd_dispatcher_ (result); - + return result; } |