aboutsummaryrefslogtreecommitdiff
path: root/core/buffer.c
diff options
context:
space:
mode:
Diffstat (limited to 'core/buffer.c')
-rw-r--r--core/buffer.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/core/buffer.c b/core/buffer.c
index 05bbb12..14ad667 100644
--- a/core/buffer.c
+++ b/core/buffer.c
@@ -69,12 +69,15 @@ int main(int argc, char *argv[]) {
for (int i = 1; i <= 10; i++)
append &= buffer_appendf(&buf, "%d", i);
ok(append && compare0(&buf, "12345678910"), "Append formatted");
-
buffer_clear(&buf);
+
append = true;
for (int i = 1; i <= 10; i++)
append &= buffer_appendf(&buf, "");
ok(append && compare0(&buf, ""), "Append formatted empty string");
+ buffer_clear(&buf);
+
+ buffer_release(&buf);
return exit_status();
}