test/multi-page: Fix use-after-free

Commit f9dcd07d22 changed the way the file name is allocated and introduced
a use-after-free in doing so.

Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
Uli Schlachter 2013-09-15 15:00:02 +02:00
parent 1d00550784
commit 440624cdf2

View file

@ -157,9 +157,9 @@ preamble (cairo_test_context_t *ctx)
draw_some_pages (surface);
cairo_surface_destroy (surface);
free (filename);
printf ("multi-page: Please check %s to ensure it looks happy.\n", filename);
free (filename);
}
#endif
@ -181,9 +181,9 @@ preamble (cairo_test_context_t *ctx)
draw_some_pages (surface);
cairo_surface_destroy (surface);
free (filename);
printf ("multi-page: Please check %s to ensure it looks happy.\n", filename);
free (filename);
}
#endif