GSList and g_filename_from_uri free memory problem
- From: Colossus <colossus 3000 it>
- To: gtk-app-devel-list gnome org
- Subject: GSList and g_filename_from_uri free memory problem
- Date: Thu, 23 Feb 2006 09:22:30 +0100
Hi,
I have this code:
gchar **array = NULL;:
array = gtk_selection_data_get_uris ( data );
while (array[len])
{
filename = g_filename_from_uri ( array[len] , NULL, NULL );
Files_to_Add = g_slist_prepend ( Files_to_Add , filename );
g_free (filename);
len++;
}
The problem is that when I free filename the GSList data becames
corrupted, but the docs says that g_filename_from_uri returns
allocated memory, so what can I do ? Once I put filename in the GSList
I don't need it anymore. Is filename freed when I call g_slist_free ?
--
Colossus
Xarchiver, a Linux GTK+2 only archive manager -
http://xarchiver.sourceforge.net
Cpsed, a Linux OpenGL 3D scene editor - http://cpsed.sourceforge.net
Mizio, a QT proxy hunter scanner tool - http://mizio.sourceforge.net
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]