From 860c71c892d4aa4ad79e31a1a2d60af9b0850e41 Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Tue, 18 Mar 2014 11:13:45 -0400 Subject: [PATCH] Fix an illegal read error in the evbuffer_add_reference tests Found with AddressSanitizer --- test/regress_buffer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/regress_buffer.c b/test/regress_buffer.c index ccb14870..00a63993 100644 --- a/test/regress_buffer.c +++ b/test/regress_buffer.c @@ -1660,7 +1660,7 @@ test_evbuffer_add_reference(void *ptr) evbuffer_add(buf1, "You shake and shake the ", 24); evbuffer_add_reference(buf1, "ketchup bottle", 14, ref_done_cb, (void*)3333); - evbuffer_add(buf1, ". Nothing comes and then a lot'll.", 42); + evbuffer_add(buf1, ". Nothing comes and then a lot'll.", 35); evbuffer_free(buf1); buf1 = NULL; tt_int_op(ref_done_cb_called_count, ==, 3);