Skip to content

Commit

Permalink
fix: memory leak in test cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
djpiper28 committed Sep 27, 2024
1 parent 6f9b7b1 commit eb165a6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/system_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ static int test_valid_queries(mse_t *state)
}

// Strip the last char (\n)
if (strlen(buffer) > 2) return 1;
if (strlen(buffer) > 2) break;
size_t last = strlen(buffer) - 1;
if (buffer[last] == '\n') {
buffer[last] = 0;
Expand Down

0 comments on commit eb165a6

Please sign in to comment.