1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-08-07 06:43:02 +03:00

Richard Jinks spotted an incoherent memory allocation behaviour in

* xpath.c: Richard Jinks spotted an incoherent memory allocation
  behaviour in xmlXPathCastToString()
Daniel
This commit is contained in:
Daniel Veillard
2002-03-22 12:23:14 +00:00
parent db5529150b
commit 4e2df54bb1
2 changed files with 6 additions and 1 deletions

View File

@@ -1,3 +1,8 @@
Fri Mar 22 13:22:09 CET 2002 Daniel Veillard <daniel@veillard.com>
* xpath.c: Richard Jinks spotted an incoherent memory allocation
behaviour in xmlXPathCastToString()
Thu Mar 21 14:25:29 CET 2002 Daniel Veillard <daniel@veillard.com> Thu Mar 21 14:25:29 CET 2002 Daniel Veillard <daniel@veillard.com>
* encoding.c: fixed a bug in the ISO-Latin 1 to UTF8 encoder * encoding.c: fixed a bug in the ISO-Latin 1 to UTF8 encoder

View File

@@ -3237,7 +3237,7 @@ xmlXPathCastToString(xmlXPathObjectPtr val) {
ret = xmlXPathCastNodeSetToString(val->nodesetval); ret = xmlXPathCastNodeSetToString(val->nodesetval);
break; break;
case XPATH_STRING: case XPATH_STRING:
return(val->stringval); return(xmlStrdup(val->stringval));
case XPATH_BOOLEAN: case XPATH_BOOLEAN:
ret = xmlXPathCastBooleanToString(val->boolval); ret = xmlXPathCastBooleanToString(val->boolval);
break; break;