Re: [Gegl-developer] status of gegl/image

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


| Dont forget to always chain up in any dispose or finalize routines...
|
| eg
|
| static void
| finalize(GObject *gobject)
| {
|
|   blah ... blah
|
|   G_OBJECT_CLASS(parent_class)->finalize(gobject);
| }

Didn't know I had to chain up on finalize and dispose, though it makes
sense.  The glib happy way of chaining up btw, is:

static void
finalize (GObject * gobject)
{
~  blah ... blah
~  G_OBJECT_CLASS (g_type_class_peek_parent (GEGL_NAME_GET_CLASS
(gobject) )->finalize(gobject);
}

| If you dont override the finalize or dispose of course
| you dont have to, but if you do, you must remember to chain up,
| else Glib with object debugging turned on (G_ENABLE_DEBUG and
G_TYPE_DEBUG_OBJECTS
| both defined) will crash in g_object_last_unref trying to dispose/finalize
| that object.

well, it doesn't crash, but aparently causes other problems.

| Also when I run the tests with the above mentioned debugging
| flags for Glib turned on, I get the following object memory leaks
| in test_gegl_memory_cache_caching:
|
| GLib-GObject-Message: stale GObjects: 9
| GLib-GObject-Message: [0x80738a0] stale GeglMockCacheEntry
ref_count=1
| GLib-GObject-Message: [0x8077998] stale GeglMockCacheEntry
ref_count=3
| GLib-GObject-Message: [0x807aa68] stale GeglMockCacheEntry
ref_count=2
| GLib-GObject-Message: [0x8075928] stale GeglMockCacheEntry
ref_count=1
| GLib-GObject-Message: [0x80789f8] stale GeglMockCacheEntry
ref_count=1
| GLib-GObject-Message: [0x807d768] stale GeglMockCacheEntry
ref_count=1
| GLib-GObject-Message: [0x8076960] stale GeglMockCacheEntry
ref_count=1
| GLib-GObject-Message: [0x8079a30] stale GeglMockCacheEntry
ref_count=1
| GLib-GObject-Message: [0x80748f0] stale GeglMockCacheEntry
ref_count=1
|
| These just mean there are some additional unrefs either in the tests or
| in the actual object code that need to be added. Look into that if
| you can...

ok.  Taking care of it.

- --
Dan
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD4DBQE/96Drad4P1+ZAZk0RAiHpAKCDSuZSjSsgkB6XIi2FJSSXx0yxWQCWKp4j
+4dKtVGrHPeMwGkjuOptCg==
=dlOR
-----END PGP SIGNATURE-----


[Index of Archives]     [Yosemite News]     [Yosemite Photos]     [gtk]     [GIMP Users]     [KDE]     [Gimp's Home]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux