summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2018-12-20 23:02:28 +0100
committerChristian Grothoff <christian@grothoff.org>2018-12-20 23:02:28 +0100
commit489c4a540bb2c4744471441425b8932b97a153e7 (patch)
treec9d445bc4c9ac86f67678e6bc3b8830dc99e3696
parentfc79fba0970033d04d847fa2a02f50eec52bc7cd (diff)
fix #5494
-rw-r--r--ChangeLog3
-rw-r--r--src/plugins/ole2_extractor.c9
2 files changed, 9 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 91568ae..64d461a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,7 @@
Thu Dec 20 22:48:47 CET 2018
Fix #5493: possible out-of-bounds read in libextractor_common
- in case of iconv() failure. -CG
+ in case of iconv() failure.
+ Fix #5494: NULL dereference in OLE2 extractor (for malformed input). -CG
Sun Dec 2 12:05:33 CET 2018
Fix #5488: do not export non-public functions from API. -CG
diff --git a/src/plugins/ole2_extractor.c b/src/plugins/ole2_extractor.c
index 53fa1b9..a48b726 100644
--- a/src/plugins/ole2_extractor.c
+++ b/src/plugins/ole2_extractor.c
@@ -173,7 +173,7 @@ struct ProcContext
EXTRACTOR_MetaDataProcessor proc;
/**
- * Closure for 'proc'.
+ * Closure for @e proc.
*/
void *proc_cls;
@@ -213,7 +213,12 @@ process_metadata (gpointer key,
if (G_VALUE_TYPE(gval) == G_TYPE_STRING)
{
- contents = strdup (g_value_get_string (gval));
+ const char *gvals;
+
+ gvals = g_value_get_string (gval);
+ if (NULL == gvals)
+ return;
+ contents = strdup (gvals);
}
else
{
https://gnunet.org