[gobject-introspection] girnode: Fix a NULL pointer defer ence if a namespace can’t be found
- From: Philip Withnall <pwithnall src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gobject-introspection] girnode: Fix a NULL pointer defer ence if a namespace can’t be found
- Date: Wed, 6 Nov 2013 14:42:40 +0000 (UTC)
commit 6838e9313ad70781ac1316a05babbbf724ecfccc
Author: Philip Withnall <philip withnall collabora co uk>
Date: Wed Nov 6 11:37:50 2013 +0000
girnode: Fix a NULL pointer deference if a namespace can’t be found
https://bugzilla.gnome.org/show_bug.cgi?id=711541
girepository/girnode.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/girepository/girnode.c b/girepository/girnode.c
index afb71e5..4361474 100644
--- a/girepository/girnode.c
+++ b/girepository/girnode.c
@@ -1151,6 +1151,10 @@ _g_ir_find_node (GIrTypelibBuild *build,
target_name = names[1];
}
+ /* find_namespace() may return NULL. */
+ if (target_module == NULL)
+ goto done;
+
for (l = target_module->entries; l; l = l->next)
{
GIrNode *node = (GIrNode *)l->data;
@@ -1162,6 +1166,7 @@ _g_ir_find_node (GIrTypelibBuild *build,
}
}
+done:
g_strfreev (names);
return return_node;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]