diff options
-rw-r--r-- | pango/shape.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/pango/shape.c b/pango/shape.c index b870ecad..401c9ec1 100644 --- a/pango/shape.c +++ b/pango/shape.c @@ -174,8 +174,9 @@ struct _PangoFcFont typedef struct _PangoFcFont PangoFcFont; #define PANGO_IS_FC_FONT(obj) \ - g_type_is_a (((GTypeInstance*)obj)->g_class->g_type, \ - g_type_from_name ("PangoFcFont")) + ((obj) != NULL && \ + g_type_is_a (((GTypeInstance*)(obj))->g_class->g_type, \ + g_type_from_name ("PangoFcFont"))) /** * pango_shape_with_flags: |