From abf6384cca0f80fe7dfb35a8e2281d8664d9d459 Mon Sep 17 00:00:00 2001 From: Randy Palamar Date: Sat, 11 Jan 2025 23:10:24 -0700 Subject: buffer: delete pointless buffer_init function lets not make the code harder to read for no reason --- test/core/buffer-test.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'test/core') diff --git a/test/core/buffer-test.c b/test/core/buffer-test.c index dfdb466..a102b01 100644 --- a/test/core/buffer-test.c +++ b/test/core/buffer-test.c @@ -15,11 +15,10 @@ static bool compare0(Buffer *buf, const char *data) { } int main(int argc, char *argv[]) { - Buffer buf; + Buffer buf = {0}; plan_no_plan(); - buffer_init(&buf); ok(buffer_content(&buf) == NULL && buffer_length(&buf) == 0 && buffer_capacity(&buf) == 0, "Initialization"); ok(buffer_insert(&buf, 0, "foo", 0) && buffer_content(&buf) == NULL && buffer_length(&buf) == 0 && buffer_capacity(&buf) == 0, "Insert zero length data"); -- cgit v1.2.3