shell: free the key in cmd_exec()

tags/0.1.0
S.J.R. van Schaik 8 years ago
parent a5e783b6bb
commit 92fc0e0ff1
  1. 4
      source/shell/cmd.c

@ -72,9 +72,11 @@ void cmd_exec(struct cmd *cmds, const char *line)
for (cmd = cmds; cmd->key; ++cmd) {
if (strcmp(cmd->key, key) == 0) {
cmd->exec(args);
return;
break;
}
}
free(key);
}
void cmd_loop(const char *show)

Loading…
Cancel
Save