After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 73088 - wrong error function context
wrong error function context
Status: VERIFIED FIXED
Product: libxslt
Classification: Platform
Component: general
unspecified
Other All
: Normal critical
: ---
Assigned To: Daniel Veillard
Daniel Veillard
Depends on:
Blocks:
 
 
Reported: 2002-03-01 06:37 UTC by Vadim Zaliva
Modified: 2009-08-15 18:40 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Vadim Zaliva 2002-03-01 06:37:04 UTC
In our code we found situation when generic error function we
provide to libxslt was called with wrong contect. Quick investigation
showed that wrong context pointer was passed. Bug appears in version 1.0.7
and cvs snapshot dated 02/28/2002  09:47:00 AM. 

This bug is pretty severe, since context is passed as void* pointer and
when casted to wrong type will most probably cause application crash when
accessed.

Here is diff file (towards said CVS snapshot) correcting this problem:

diff -u -rp XSLT.orig/libxslt/preproc.c XSLT/libxslt/preproc.c
--- XSLT.orig/libxslt/preproc.c	Thu Oct 18 00:45:09 2001
+++ XSLT/libxslt/preproc.c	Thu Feb 28 22:31:04 2002
@@ -1326,7 +1326,7 @@ xsltStylePreCompute(xsltStylesheetPtr st
 
			(xsltTransformFunction) xsltDocumentElem);
 	} else {
 	    xsltPrintErrorContext(NULL, style, inst);
-
    xsltGenericError(xsltGenericDebugContext,
+
    xsltGenericError(xsltGenericErrorContext,
 
	 "xsltStylePreCompute: unknown xsl:%s\n", inst->name);
 	    style->warnings++;
 	}
Comment 2 Daniel Veillard 2002-03-18 21:43:56 UTC
This should be fixed in the recent releases,

 thanks !

Daniel