Commit 0ba5765317fb1699bc61c1e4875195ecd4b7e773

Thomas de Grivel 2024-07-29T18:26:36

fix buf_test_read_to_str

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/test/buf_test.c b/test/buf_test.c
index 9f804b8..fcaddf0 100644
--- a/test/buf_test.c
+++ b/test/buf_test.c
@@ -118,7 +118,7 @@
     s_str result;                                                      \
     test_context("buf_read_to_str(" # test ")");                       \
     buf_init_1(&buf, false, (test));                                   \
-    TEST_EQ(buf_read_to_str(&buf, &result), strlen(test));             \
+    TEST_EQ(buf_read_to_str(&buf, &result), &result);                  \
     TEST_EQ(buf.rpos, strlen(test));                                   \
     str_clean(&result);                                                \
     test_context(NULL);                                                \