Re: color "scribble-simple" eats up all memory & crashes
- From: Havoc Pennington <hp redhat com>
- To: Cevat Ustun <ustun Glue umd edu>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: color "scribble-simple" eats up all memory & crashes
- Date: 13 Feb 2001 18:45:31 -0500
Cevat Ustun <ustun Glue umd edu> writes:
I have written a simple application that draws a series of points
given a starting point and gradually fills the screen (based on
scribble-simple.c from the gtk tutorials). The black &white version
works flawlessly but the color version quickly swells up all the
memory taken by X and ultimately crashes. Why?
You're leaking the graphics context, you have to free it. Also you
want to use gtk_widget_queue_draw(), not gtk_widget_draw() for
efficiency.
Havoc
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]