diff options
author | James Booth <boothj5@gmail.com> | 2012-04-28 19:08:31 +0100 |
---|---|---|
committer | James Booth <boothj5@gmail.com> | 2012-04-28 19:08:31 +0100 |
commit | 2b51d416317e69bdb9f34ec9035fe3af51627a0c (patch) | |
tree | 38ff16508add540e48aae8659595ef100263d9ca | |
parent | 3fa7931d53c9f90fe561eb51d966a878a23b12b8 (diff) | |
download | profani-tty-2b51d416317e69bdb9f34ec9035fe3af51627a0c.tar.gz |
Revert "Free split args in command.c"
This reverts commit 161157a1c868746d052924bd590c5cfd9f7a75f7.
-rw-r--r-- | command.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/command.c b/command.c index 5ecb015e..de36e732 100644 --- a/command.c +++ b/command.c @@ -81,10 +81,8 @@ static struct command_t _parse_command(char *str) struct command_t cmd; char **split = g_strsplit(str, " ", 0); - cmd.command = malloc((strlen(split[0]) + 1) * sizeof(char)); - strcpy(cmd.command, split[0]); + cmd.command = split[0]; cmd.params = NULL; - g_strfreev(split); return cmd; } |