summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliam Casarin <jb55@jb55.com>2018-07-13 10:29:28 -0700
committerWilliam Casarin <jb55@jb55.com>2018-07-13 10:29:28 -0700
commit62a9e6b170d9c7474e77de31c46d5d35f0cda0ba (patch)
tree10206f0828b68bd86c12622af61fc80fd2be0672
parent4f0b9cf334f0a763ff1fcfaabb61796f412a6452 (diff)
let's keep it simple for now
-rw-r--r--command.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/command.c b/command.c
index 1703f99..f3b0e91 100644
--- a/command.c
+++ b/command.c
@@ -8,13 +8,6 @@
#include "util.h"
-static const char *
-bind_name_to_bind(const char *bind) {
- if (strcmp(bind, "STR") == 0)
- return " ";
- return bind;
-}
-
int
command_is_prefix(struct command *cmd) {
return cmd->nchildren > 0;
@@ -35,7 +28,7 @@ command_num_children(struct command *cmd) {
struct command *
command_lookup(struct command *cmd, int ncmds, const char *binding) {
for (int i = 0; i < ncmds; ++i) {
- if (strcmp(binding, bind_name_to_bind(cmd[i].bind)) == 0)
+ if (strcmp(binding, cmd[i].bind) == 0)
return &cmd[i];
}