diff options
author | Adrian Kummerländer | 2014-05-29 23:01:36 +0200 |
---|---|---|
committer | Adrian Kummerländer | 2014-05-29 23:01:36 +0200 |
commit | e402a092a5e2fbf624947896b013d405efb75049 (patch) | |
tree | fc43b178b39ff56669de5e9d3778019347e88d9a /patch | |
parent | 3bc793d95293d40dbab62c593ce4ceaa86fae25b (diff) | |
download | InputXSLT-e402a092a5e2fbf624947896b013d405efb75049.tar InputXSLT-e402a092a5e2fbf624947896b013d405efb75049.tar.gz InputXSLT-e402a092a5e2fbf624947896b013d405efb75049.tar.bz2 InputXSLT-e402a092a5e2fbf624947896b013d405efb75049.tar.lz InputXSLT-e402a092a5e2fbf624947896b013d405efb75049.tar.xz InputXSLT-e402a092a5e2fbf624947896b013d405efb75049.tar.zst InputXSLT-e402a092a5e2fbf624947896b013d405efb75049.zip |
Fixed error handling of invalid XSL transformations
* xalan is segfaulting in XalanDOMString constructor when the static member "XalanLocator::getSystemId" is returning null-pointer
** this should seemingly be handled by passing a pointer to the static constant m_dummy but this sadly fails to prevent the segfault
** the patch provided by this commit fixes the problem for now but I cannot guarantee that this wont cause any side effects in a other context
* Adapted TransformationFacade to handle errors during transformation compilation
** errors generated during transformation compilation are returned through the generate member method
** throwing an exeception during TransformationFacade construction would require additional error handling in the calling code
* Added xalan::ProblemListener functionality to the ErrorHandler class
** XSLT problems passed to the ProblemListener are returned alongside to and treated as all other transformation errors
Diffstat (limited to 'patch')
-rw-r--r-- | patch/XSLException.patch | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/patch/XSLException.patch b/patch/XSLException.patch new file mode 100644 index 0000000..a67f265 --- /dev/null +++ b/patch/XSLException.patch @@ -0,0 +1,15 @@ +--- xalan-c-1.11_original/c/src/xalanc/PlatformSupport/XSLException.cpp 2014-05-29 22:27:20.366792350 +0200 ++++ xalan-c-1.11_patched/c/src/xalanc/PlatformSupport/XSLException.cpp 2014-05-29 22:56:01.136185453 +0200 +@@ -41,11 +41,7 @@ + const Locator* theLocator) : + m_memoryManager(theManager), + m_message(theMessage, theManager), +- m_uri( +- XalanLocator::getSystemId( +- theLocator, +- &s_dummy), +- theManager), ++ m_uri(theLocator == 0 ? s_dummy : theLocator->getSystemId()), + m_lineNumber(XalanLocator::getLineNumber(theLocator)), + m_columnNumber(XalanLocator::getColumnNumber(theLocator)), + m_formatted(false) |