summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--girepository/gitypelib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/girepository/gitypelib.c b/girepository/gitypelib.c
index a643cde1..d88924a6 100644
--- a/girepository/gitypelib.c
+++ b/girepository/gitypelib.c
@@ -294,7 +294,7 @@ g_typelib_matches_gtype_name_prefix (GITypelib *typelib,
gsize gtype_name_len;
c_prefix = g_typelib_get_string (typelib, header->c_prefix);
- if (c_prefix == NULL)
+ if (c_prefix == NULL || strlen (c_prefix) == 0)
return FALSE;
gtype_name_len = strlen (gtype_name);