Re: newbie question about g_object unref()
- From: Leandro Pereira <leandro hardinfo org>
- To: Nader Morshed <morshed nader gmail com>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: newbie question about g_object unref()
- Date: Thu, 18 Nov 2010 21:48:44 -0200
Nader Morshed,
On Thu, Nov 18, 2010 at 8:21 PM, Nader Morshed <morshed nader gmail com> wrote:
#define G_OBJECT_UNREF_AND_NULLIFY(ptr) { \
   Âg_object_unref(ptr); \
   Â(ptr) = NULL; \
}
Not a good idea: the object may still hold a reference, and nullifying
the pointer would probably nullify the only way to access the object.
Cheers,
Leandro
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]