diff options
author | Nicholas Marriott <nicholas.marriott@gmail.com> | 2007-10-04 21:48:11 +0000 |
---|---|---|
committer | Nicholas Marriott <nicholas.marriott@gmail.com> | 2007-10-04 21:48:11 +0000 |
commit | 75e1e4b91e083c82f48de5f426b3cfc6c7c5a7df (patch) | |
tree | 66f7cb600434ebfd34166f3e4ebf4257ee3cb986 /cmd-bind-key.c | |
parent | 5a3b92c2dfd9fbcf8bda10742cea1fb47927536d (diff) |
Lose usage and move it into the struct.
Diffstat (limited to 'cmd-bind-key.c')
-rw-r--r-- | cmd-bind-key.c | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/cmd-bind-key.c b/cmd-bind-key.c index 4f771c12..bb100634 100644 --- a/cmd-bind-key.c +++ b/cmd-bind-key.c @@ -1,4 +1,4 @@ -/* $Id: cmd-bind-key.c,v 1.2 2007-10-04 10:11:32 nicm Exp $ */ +/* $Id: cmd-bind-key.c,v 1.3 2007-10-04 21:48:11 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -27,7 +27,6 @@ */ int cmd_bind_key_parse(void **, int, char **, char **); -const char *cmd_bind_key_usage(void); void cmd_bind_key_exec(void *, struct cmd_ctx *); void cmd_bind_key_send(void *, struct buffer *); void cmd_bind_key_recv(void **, struct buffer *); @@ -39,9 +38,9 @@ struct cmd_bind_key_data { }; const struct cmd_entry cmd_bind_key_entry = { - CMD_BINDKEY, "bind-key", "bind", CMD_NOSESSION, + CMD_BINDKEY, "bind-key", "bind", "key command [arguments]", + CMD_NOSESSION, cmd_bind_key_parse, - cmd_bind_key_usage, cmd_bind_key_exec, cmd_bind_key_send, cmd_bind_key_recv, @@ -81,19 +80,14 @@ cmd_bind_key_parse(void **ptr, int argc, char **argv, char **cause) return (0); usage: - usage(cause, "%s", cmd_bind_key_usage()); + usage(cause, "%s %s", + cmd_bind_key_entry.name, cmd_bind_key_entry.usage); error: cmd_bind_key_free(data); return (-1); } -const char * -cmd_bind_key_usage(void) -{ - return ("bind-key key command [arguments]"); -} - void cmd_bind_key_exec(void *ptr, unused struct cmd_ctx *ctx) { |