From f3d03e71ede8e94e7137777ab5ad5570c3d11b31 Mon Sep 17 00:00:00 2001 From: iceyrazor Date: Fri, 6 Mar 2026 22:34:50 -0600 Subject: some cleanup and shell var - SHELL is now set - cwd now has realloc - realloc with error checking is now a fucntion like malloce --- src/lsh_split_line.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/lsh_split_line.c') 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); -- cgit v1.3