From: Daniel Veillard Date: Sat, 11 Feb 2006 12:14:10 +0000 (+0000) Subject: fix xsltSaveResultToString comment detect loops when computing variables, X-Git-Tag: v1.1.28~271 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e9517d8c4a08b28e51ec847946630dc56823b6bc;p=platform%2Fupstream%2Flibxslt.git fix xsltSaveResultToString comment detect loops when computing variables, * libxslt/xsltutils.c: fix xsltSaveResultToString comment * libxslt/transform.c: detect loops when computing variables, should fix bug #330772 * doc/xsltproc.xml doc/xsltproc.1: fix typo in man page * tests/namespaces/tst7.out tests/general/bug-152.out: small output changes due to libxml2 xhtml meta handling modification Daniel --- diff --git a/ChangeLog b/ChangeLog index 1203ccd..97e342f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +Sat Feb 11 13:10:01 CET 2006 Daniel Veillard + + * libxslt/xsltutils.c: fix xsltSaveResultToString comment + * libxslt/transform.c: detect loops when computing variables, should + fix bug #330772 + * doc/xsltproc.xml doc/xsltproc.1: fix typo in man page + * tests/namespaces/tst7.out tests/general/bug-152.out: small output + changes due to libxml2 xhtml meta handling modification + Mon Nov 21 12:22:21 CET 2005 Daniel Veillard * libexslt/date.c: Albert Chin found another signed/unsigned problem diff --git a/doc/xsltproc.1 b/doc/xsltproc.1 index 460bcc1..7830802 100644 --- a/doc/xsltproc.1 +++ b/doc/xsltproc.1 @@ -98,7 +98,7 @@ Do not use the Internet to fetch DTD's, entities or documents\&. .TP \fB\-\-path\fR \fIpaths\fR -Use the list (separated by space or column) of filesystem paths specified by \fIpaths\fR to load DTDs, entities or documents\&. +Use the list (separated by space or colon) of filesystem paths specified by \fIpaths\fR to load DTDs, entities or documents\&. .TP \fB\-\-load\-trace\fR diff --git a/doc/xsltproc.xml b/doc/xsltproc.xml index f759506..3102ac2 100644 --- a/doc/xsltproc.xml +++ b/doc/xsltproc.xml @@ -250,7 +250,7 @@ paths - Use the list (separated by space or column) of filesystem paths + Use the list (separated by space or colon) of filesystem paths specified by paths to load DTDs, entities or documents. diff --git a/libxslt/transform.c b/libxslt/transform.c index 5bd4d40..b9f7538 100644 --- a/libxslt/transform.c +++ b/libxslt/transform.c @@ -1554,7 +1554,8 @@ xsltApplyOneTemplateInt(xsltTransformContextPtr ctxt, xmlNodePtr node, return; CHECK_STOPPED; - if (ctxt->templNr >= xsltMaxDepth) { + if ((ctxt->templNr >= xsltMaxDepth) || + (ctxt->varsNr >= 5 * xsltMaxDepth)) { xsltTransformError(ctxt, NULL, list, "xsltApplyOneTemplate: loop found ???\n"); xsltGenericError(xsltGenericErrorContext, diff --git a/libxslt/xsltutils.c b/libxslt/xsltutils.c index af762f7..78f30cd 100644 --- a/libxslt/xsltutils.c +++ b/libxslt/xsltutils.c @@ -1544,9 +1544,9 @@ xsltSaveResultToFd(int fd, xmlDocPtr result, xsltStylesheetPtr style) { * @style: the stylesheet * * Save the result @result obtained by applying the @style stylesheet - * to a file or @URL + * to a new allocated string. * - * Returns the number of byte written or -1 in case of failure. + * Returns 0 in case of success and -1 in case of error */ int xsltSaveResultToString(xmlChar **doc_txt_ptr, int * doc_txt_len, diff --git a/tests/general/bug-152.out b/tests/general/bug-152.out index 3d23ac9..7bdd337 100644 --- a/tests/general/bug-152.out +++ b/tests/general/bug-152.out @@ -1,7 +1,8 @@ - + + diff --git a/tests/namespaces/tst7.out b/tests/namespaces/tst7.out index 47cc1e7..b86f605 100644 --- a/tests/namespaces/tst7.out +++ b/tests/namespaces/tst7.out @@ -1,7 +1,8 @@ - + + A title