GNOME Bugzilla – Bug 617972
Handle destroy callbacks of type other than GDestroyNotify
Last modified: 2010-05-07 16:11:53 UTC
It's not necessary that a destroy callback is literally of type GDestroyNotify - we can handle any 'void (*function) (void *)' So instead of checking against the type of the callback to see what to skip, look for a callback that was previously used as a GDestroyNotify for another callback.
Created attachment 160467 [details] [review] Handle destroy callbacks of type other than GDestroyNotify
Review of attachment 160467 [details] [review]: Right, looks OK assuming we've validated the destroy notify index in the scanner.
(In reply to comment #2) > Review of attachment 160467 [details] [review]: > > Right, looks OK assuming we've validated the destroy notify index in the > scanner. Doesn't look easy to do - we parse the included gir's, but then we dump the parsed results other than the type names, so at the point where we are parsing annotations, we have no idea what GLib.FreeFunc is. It's not like there aren't a million other ways to segfault if you have bad annotations...
Hmm. Ok.
Attachment 160467 [details] pushed as 62cf04d - Handle destroy callbacks of type other than GDestroyNotify