proplib: fix a NULL pointer dereference when internalizing empty blobs.

_prop_object_internalize_context_alloc: make sure that passed xml string
is not NULL before derefering it a bit later.
This commit is contained in:
Juan RP 2015-05-28 09:14:28 +02:00
parent 0027e54532
commit fd30a00cb4

View File

@ -692,6 +692,9 @@ _prop_object_internalize_context_alloc(const char *xml)
{
struct _prop_object_internalize_context *ctx;
if (xml == NULL)
return NULL;
ctx = _PROP_MALLOC(sizeof(struct _prop_object_internalize_context),
M_TEMP);
if (ctx == NULL)