summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGravatar Nikias Bassen2017-01-19 17:44:42 +0100
committerGravatar Nikias Bassen2017-01-19 17:44:42 +0100
commit6a44dfb72f1cb5c82c10feed95ff9428eec49d0a (patch)
tree7993405191f22708e03706280eec72f13dc4297e /src
parentc67ab063cf82306067f3a0ebdbf4f7d6dff94a2a (diff)
downloadlibplist-6a44dfb72f1cb5c82c10feed95ff9428eec49d0a.tar.gz
libplist-6a44dfb72f1cb5c82c10feed95ff9428eec49d0a.tar.bz2
bplist: Check for invalid ref_size in bplist trailer
Diffstat (limited to 'src')
-rw-r--r--src/bplist.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/bplist.c b/src/bplist.c
index 7ab9380..7cc8a03 100644
--- a/src/bplist.c
+++ b/src/bplist.c
@@ -727,6 +727,9 @@ PLIST_API void plist_from_bin(const char *plist_bin, uint32_t length, plist_t *
if (offset_size == 0)
return;
+ if (ref_size == 0)
+ return;
+
if (root_object >= num_objects)
return;