1
0
mirror of https://gitlab.gnome.org/GNOME/libxslt synced 2025-09-15 16:01:08 +03:00
Files
libxslt/tests/general/bug-209.xsl
Nick Wellnhofer 8bd32f7753 Fix handling of RVTs returned from nested EXSLT functions
Set the context variable to NULL when evaluating EXSLT functions.
Fixes potential use-after-free errors or memory leaks.

Fixes bug 792580. Thanks to Clemens Gutweiler for the report.

https://bugzilla.gnome.org/show_bug.cgi?id=792580
2018-01-16 19:01:55 +01:00

22 lines
546 B
XML

<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:func="http://exslt.org/functions"
extension-element-prefixes="func">
<xsl:template match="/">
<xsl:variable name="v" select="func:a()" />
<xsl:copy-of select="$v"/>
</xsl:template>
<func:function name="func:a">
<func:result select="func:b()" />
</func:function>
<func:function name="func:b">
<func:result>
<result/>
</func:result>
</func:function>
</xsl:stylesheet>