Monthly Archives: November 2015

attribute((cleanup)), mixed declarations and code, and goto.

One of the cool features of recent GLib is g_autoptr() and g_autofree. It’s liberating to be able to write: g_autofree char *filename = g_strdup_printf(“%s/%d.txt”, dir, count); And be sure that will be freed no matter how your function returns. But as I started to use it, I realized that I wasn’t very sure about some […]