Re: [gtk-vnc-devel] [PATCH] Gtk-VNC not packed
- From: Anthony Liguori <anthony codemonkey ws>
- To: "Richard W.M. Jones" <rjones redhat com>
- Cc: gtk-vnc-devel List <gtk-vnc-devel lists sourceforge net>
- Subject: Re: [gtk-vnc-devel] [PATCH] Gtk-VNC not packed
- Date: Tue, 15 Jan 2008 10:32:57 -0600
Richard W.M. Jones wrote:
Anthony Liguori wrote:
Richard W.M. Jones wrote:
I don't know if you necessarily want to classify this as a bug, but
currently if you create a Gtk-VNC widget but don't pack it, then it
will segfault when it tries to draw anything.
I'm not sure what "packed" is. Do we need to wait for realize or
something? My concern with this patch is that the buffer disappears
until the next resize so when things to get "packed" we don't start
displaying like we should.
Sorry, I wasn't clear. This is when you create a Gtk-VNC widget but
don't add it to any container, but then you do make it connect to a
VNC server. The widget segfaults, because the return value from
gdk_drawable_get_visual (GTK_WIDGET(obj)->window)
is NULL, and you get a segfault a couple of lines later when visual is
dereferenced.
This shouldn't affect any code which does pack the widget in a
container (visual != NULL).
Yes, but that's not my concern. My concern is if you connect a widget
before packing it, and then wait a while before actually packing it.
When you pack it, you need to make sure it's displaying stuff.
This is why I suggested listening for the realized signal. I think this
is the thing that indicates that a visual is now valid.
Regards,
Anthony Liguori
Rich.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]