What's wrong with floating objects?
- From: "Adrian E. Feiguin" <afeiguin uci edu>
- To: gtk-list gnome org
- Subject: What's wrong with floating objects?
- Date: Wed, 02 Feb 2005 14:09:12 -0800
What's wrong with floating objects? I have created and array and matrix
class, and I play with reference counting. Sometimes I need to create a
temporary object that I free right away after some manipulation, and I
always get gobject to complain that ...
Gtk-WARNING **: A floating object was finalized. This means
that someone
called g_object_unref() on an object that had only a floating
reference; the initial floating reference is not owned by anyone
and must be removed with gtk_object_sink() after a normal
reference is obtained with g_object_ref().
Why would I want to sink it? Can anybody explain the logic behind it?
It's not clear to me from the documentation, and it's not practical for
my application. Thanks!
<ADRIAN>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]