Re: Can I use gtk_widget_unref() to releasetthe object created by gtk_invisible_new()?
- From: Shaun McCance <shaunm gnome org>
- To: Brian Lu <Brian Lu Sun COM>
- Cc: gnome-list gnome org
- Subject: Re: Can I use gtk_widget_unref() to releasetthe object created by gtk_invisible_new()?
- Date: Sun, 13 Jan 2008 18:48:49 -0600
On Tue, 2008-01-08 at 18:07 +0800, Brian Lu wrote:
> Hi, experts,
>
> I found following codes will crash in gnome 2.21 environment:
>
> ...
> GtkWidget *foo = gtk_invisible_new();
> gtk_widget_unref(foo);
> ...
>
> But it works well if gtk_widget_unref() is replaced with
> gtk_widget_destroy().
>
> Does that mean that we can't use gtk_widget_unref() on such object and
> we can only
> use gtk_widget_destroy() to release it?
I suspect it's because you never called
gtk_widget_ref on foo before you unref'd
it.
--
Shaun
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]