diff --git a/fx/object.c b/fx/object.c index 17b859b..a89936c 100644 --- a/fx/object.c +++ b/fx/object.c @@ -100,6 +100,10 @@ fx_status fx_object_to_string( bool fx_object_is_type(const struct _fx_object *p, fx_type_id type) { + if (!p) { + return false; + } + if (fx_type_id_compare(&p->obj_type->ty_id, type) == 0) { return true; }