Browse Source

* fix cppcheck warnings

master
Alex 'AdUser' Z 8 years ago
parent
commit
eb8e5f2842
  1. 2
      src/commands.c
  2. 2
      src/jail.c

2
src/commands.c

@ -12,7 +12,7 @@ struct f2b_cmd_t {
const char *help;
const char *tokens[CMD_TOKENS_MAX];
char *data;
} commands[] = {
} commands[CMD_MAX_NUMBER] = {
[CMD_NONE] = {
.tokens = { NULL },
.help = "Unspecified command"

2
src/jail.c

@ -77,7 +77,7 @@ f2b_jail_apply_config(f2b_jail_t *jail, f2b_config_section_t *section) {
}
if (strcmp(param->name, "maxretry") == 0) {
jail->maxretry = atoi(param->value);
if (jail->maxretry <= 0)
if (jail->maxretry == 0)
jail->maxretry = DEFAULT_MAXRETRY;
continue;
}

Loading…
Cancel
Save