shell: remove useless copying of input string
This commit is contained in:
parent
14cb81d914
commit
33239487bf
@ -90,10 +90,8 @@ static void print_help(const shell_command_t *command_list)
|
|||||||
|
|
||||||
static void handle_input_line(shell_t *shell, char *line)
|
static void handle_input_line(shell_t *shell, char *line)
|
||||||
{
|
{
|
||||||
char line_copy[shell->shell_buffer_size];
|
|
||||||
char *saveptr;
|
char *saveptr;
|
||||||
strncpy(line_copy, line, sizeof(line_copy));
|
char *command = strtok_r(line, " ", &saveptr);
|
||||||
char *command = strtok_r(line_copy, " ", &saveptr);
|
|
||||||
|
|
||||||
void (*handler)(char *) = NULL;
|
void (*handler)(char *) = NULL;
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user