diff options
| author | iceyrazor <iceyrazor@mailfence.com> | 2026-03-06 22:34:50 -0600 |
|---|---|---|
| committer | iceyrazor <iceyrazor@mailfence.com> | 2026-03-06 22:34:50 -0600 |
| commit | f3d03e71ede8e94e7137777ab5ad5570c3d11b31 (patch) | |
| tree | ddd17a5e3e1c40e645772cb9466169b98389985d /src/lsh_split_line.c | |
| parent | 5964950ca5c018e1163fe308fa4bb17b9220b383 (diff) | |
some cleanup and shell var
- SHELL is now set
- cwd now has realloc
- realloc with error checking is now a fucntion like malloce
Diffstat (limited to 'src/lsh_split_line.c')
| -rw-r--r-- | src/lsh_split_line.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/lsh_split_line.c b/src/lsh_split_line.c index ff4f644..17e16a7 100644 --- a/src/lsh_split_line.c +++ b/src/lsh_split_line.c @@ -164,11 +164,7 @@ char **lsh_split_line(char *line) if (position >= bufsize) { bufsize += LSH_TOK_BUFSIZE; - tokens = realloc(tokens, bufsize * sizeof(char*)); - if (!tokens) { - fprintf(stderr, "lsh: allocation error\n"); - exit(EXIT_FAILURE); - } + tokens = realloce(tokens, bufsize * sizeof(char*)); } token = strtok_quotes(NULL); |
