Hi John,
Thanks for the response. I figured out a solution later.
It turns out that freeing the PangoContext using g_object_unref() also frees the associated PangoFontDescription.
I was doing the mistake of freeing the PangoFontDescription again, by using pango_font_description_free().
However, I am curious why memory corruption occurs only after multiple executions.
Thanks and regards,
Parth Kanungo
------- Original Message -------
Sender : John Ralls<jralls ceridwen us>
Date : Feb 20, 2014 21:04 (GMT+05:30)
Title : Re: Crash in g_slice_alloc()
Some more information...
The exact location of crash is the following statement in magazine_chain_pop_head() function in gslice.c
if (G_UNLIKELY (chunk))
{
/* allocating from freed list */
(*magazine_chunks)->data = "">
}