allocating mem using glib



hi there,

i have a question about allocating/deallocating memory using glib
i have created this simple app to demonstrate :
http://pastebin.com/kVncSgxh
the app creates a simple GSList list and fill it with a data structure of type item_data
 
at line 65 i use a loop to free mem allocated by malloc() and by g_new();
i really need to know if i'm allocating/deallocating memory in the correct way



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]