aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2011-08-24 22:05:33 +0000
committerSergey Poznyakoff <gray@gnu.org.ua>2011-08-24 22:05:33 +0000
commit3c0819116085a1a8fcae21608c388f3d5dc0531f (patch)
tree7d7418f896997e4a67b0f1deb5af917493bf7a12 /src
parent7ea0c0578a59abc086496024dbf6cc65b6e94e38 (diff)
downloadgdbm-3c0819116085a1a8fcae21608c388f3d5dc0531f.tar.gz
gdbm-3c0819116085a1a8fcae21608c388f3d5dc0531f.tar.bz2
Minor fix.
* src/testgdbm.c: Minor fix.
Diffstat (limited to 'src')
-rw-r--r--src/testgdbm.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/src/testgdbm.c b/src/testgdbm.c
index 9c0ad8f..b22e343 100644
--- a/src/testgdbm.c
+++ b/src/testgdbm.c
@@ -728,7 +728,7 @@ import_handler (char *arg[NARGS], FILE *fp, void *call_data ARG_UNUSED)
}
static const char *
-boolstr(int val)
+boolstr (int val)
{
return val ? _("yes") : _("no");
}
@@ -955,13 +955,11 @@ find_command (char *str)
struct command *cmd;
size_t len = strlen (str);
- if (len > 1)
- {
- for (cmd = command_tab; cmd->name; cmd++)
- if (len >= cmd->minlen && memcmp (cmd->name, str, len) == 0)
- return cmd;
- }
- else
+ for (cmd = command_tab; cmd->name; cmd++)
+ if (len >= cmd->minlen && memcmp (cmd->name, str, len) == 0)
+ return cmd;
+
+ if (len == 1)
{
for (cmd = command_tab; cmd->name; cmd++)
if (cmd->abbrev == *str)

Return to:

Send suggestions and report system problems to the System administrator.