xiangbing <xb_parasite@xxxxxxx> writes: Hi Xiang, > GTimer * timer; > g_timer_start (timer) ; You may not pass NULL to g_timer_start, not to mention wild pointers. Instead, you must call g_timer_new to create a GTimer. So the above code should look like this: GTimer *timer = g_timer_new (); You don't even have to call g_timer_start, because it turns out g_timer_new will automatically start the timer for you. All this and more is covered in the GLib Reference Manual[1], section GLib Utilities, Timers[2]. Hope this helps, -- Daniel Brockman drlion@xxxxxxxxxxxx [1] http://developer.gnome.org/doc/API/2.0/glib/ [2] http://developer.gnome.org/doc/API/2.0/glib/glib-Timers.html _______________________________________________ gtk-list@xxxxxxxxx http://mail.gnome.org/mailman/listinfo/gtk-list