loop #2

Merged
cromer merged 11 commits from loop into master 2021-06-19 23:03:40 -04:00
Showing only changes of commit b5e4de3f82 - Show all commits

View File

@ -40,6 +40,7 @@ void loop() {
if (feof(stdin)) { if (feof(stdin)) {
// the stdin was closed, this usually happens for CTRL-D // the stdin was closed, this usually happens for CTRL-D
printf("\n"); printf("\n");
free(line);
break; break;
} }
else { else {
@ -52,6 +53,7 @@ void loop() {
remove_new_line(line); remove_new_line(line);
if (strcmp(line, "quit") == 0) { if (strcmp(line, "quit") == 0) {
free(line);
break; break;
} }
} }