the g_sprintf returns the number of characters, so i should use it like the normal sprintf, gchar *mapper_chk_cmd; g_sprintf(mapper_chk_cmd, "/dev/mapper/%s", data);
but it doesnt seem to help, the segfault is there, too when i init it with gchar mount_chk_cmd[128]; i can use it like with sprintf, but i cant free the memory for these gchars. I got the warning with the g_sprintf, but i think it was because it returned int i removed the fclose and pclose, but the app also crashed after a while with the same symptoms. On 8/27/06, Peter Firefly Lund <[EMAIL PROTECTED]> wrote: > > On Sun, 27 Aug 2006, rupert wrote: > > > mh, i noticed that, but when i the fclose in the line before return TRUE > i > get a segfault. > > You are papering over another fault. Find that and fix it instead. > > It might be that sprintf() creates a string that is too big for the buffer > you allocated. Such things can be quite unhealthy, which is why one > should use g_sprintf() instead. > > -Peter > _______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list