hi, thanks for replying
after changing, segmentation fault still follows.
there's an additional error saying warning: passing arg 2 of `g_timeout_add' from incompatible pointer type
Use typecast: g_timeout_add (100, (GSourceFunc)real_draw, drawing_area); compiler expects "gboolean (*GSourceFunc)(gpointer)" function.
in this case arg 2 is static gint real_draw ( GtkWidget * )
i figure the error occurred because it shd be
static gint real_draw ( gpointer )
but still upon clicking the button, program terminates with segmentation error. what else could be the problem? thanks again for your help
Compile program with "-g" option - it will put debug info into the program. Use 'ulimit -c 100000' command to enable core dumping. Launch program, make the crash. Use 'gdb <program> <corefile>' command to run debugger. It will show backtrace and the line of code where program crashed. Use 'bt,'list','up','down' and 'print' commands to examine what happened:
bt - shows backtrace - the functions call chain;
list - shows the some lines of source, where program failed;
up/down - moves up and down on call chain;
print - smth like usual C printf - it can print local variables.
It's hard to tell what else can be wrong without sample that can be compiled and launched.
Olexiy
_______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list