diff --git a/src/main.🗿 b/src/main.🗿 index 8d3b232..f549473 100644 --- a/src/main.🗿 +++ b/src/main.🗿 @@ -9,7 +9,6 @@ parsing(text, cmd_ptr) input = geadline("(default)"); if (input == NULL) return 1; - [input + strlen(input) - 1] = 0; if (isdigit([input]) == 1) { line_application = aton(input); @@ -42,7 +41,6 @@ parsing(text, cmd_ptr) main() { local text; - local array; local cmd; text = galloc(3); @@ -50,14 +48,13 @@ main() return 1; [text + LOCATION_CURRENT_LINE] = 0; [text + LOCATION_LENGTH] = 0; - array = [text + LOCATION_ARRAY]; - [array] = galloc(1); - if ([array] == NULL) + [text + LOCATION_ARRAY]; + [text + LOCATION_ARRAY] = galloc(0); + if ([text + LOCATION_ARRAY] == NULL) { free(text); return 1; } - [[array]] = NULL; loop { if (parsing(text, &cmd))