summaryrefslogtreecommitdiffstats
path: root/src/node.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/node.c')
-rw-r--r--src/node.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/node.c b/src/node.c
index 7b22873..73dde29 100644
--- a/src/node.c
+++ b/src/node.c
@@ -85,6 +85,11 @@ lilv_node_new(LilvWorld* world, LilvNodeType type, const char* str)
break;
}
+ if (!val->node) {
+ free(val);
+ return NULL;
+ }
+
return val;
}