summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/xplist.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/xplist.c b/src/xplist.c
index f896030..a6737fb 100644
--- a/src/xplist.c
+++ b/src/xplist.c
@@ -1265,6 +1265,9 @@ static void node_from_xml(parse_ctx ctx, plist_t *plist)
free(path_item);
parent = ((node_t*)parent)->parent;
+ if (!parent) {
+ goto err_out;
+ }
}
free(tag);