Do not crash when checking whether an instance type is of a given fundamental.
authorAndre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>
Wed, 30 Jul 2014 00:04:48 +0000 (21:04 -0300)
committerEdward Hervey <edward@collabora.com>
Fri, 8 Aug 2014 09:13:01 +0000 (11:13 +0200)
commit4b5bdf6cebc4c1b7c6db7e23c678cc2f5003e757
tree7a8b0b9ee9aad73f453765e1e31056c1319f7c7c
parent5053054c629c3ead90ec3c6fa1fc0fa642476d46
Do not crash when checking whether an instance type is of a given fundamental.

Not all instances have a TypeNode associated (e.g. GstEvent), so lets check if node is available
before trying to use it.

This crash can be easily reproduced by creating an event with gst_event_new_eos and using
G_IS_OBJECT on the event instance.

https://bugzilla.gnome.org/show_bug.cgi?id=733982
gobject/gtype.c