From 4dd5a5e18d4d3184ce4c97e0bcd9e97ebb267831 Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Mon, 7 Jan 2013 15:29:15 -0600 Subject: [PATCH] Fix last leak in test-pangocairo-threads --- tests/test-pangocairo-threads.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/test-pangocairo-threads.c b/tests/test-pangocairo-threads.c index 520f7c3..6d49760 100644 --- a/tests/test-pangocairo-threads.c +++ b/tests/test-pangocairo-threads.c @@ -82,10 +82,12 @@ main (int argc, char **argv) for (i = 0; i < num_threads; i++) { + char buf[10]; cairo_surface_t *surface = create_surface (); g_ptr_array_add (surfaces, surface); + snprintf (buf, sizeof (buf), "%d", i); g_ptr_array_add (threads, - g_thread_new (g_strdup_printf ("%d", i), + g_thread_new (buf, thread_func, surface)); } -- 2.7.4