summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libxslt/functions.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libxslt/functions.c b/libxslt/functions.c
index e13cc98b..9706a7af 100644
--- a/libxslt/functions.c
+++ b/libxslt/functions.c
@@ -558,6 +558,10 @@ xsltUnparsedEntityURIFunction(xmlXPathParserContextPtr ctxt, int nargs){
obj = valuePop(ctxt);
if (obj->type != XPATH_STRING) {
obj = xmlXPathConvertString(obj);
+ if (obj == NULL) {
+ xmlXPathErr(ctxt, XPATH_MEMORY_ERROR);
+ return;
+ }
}
str = obj->stringval;