[Libreoffice-commits] core.git: sax/source

Matúš Kukan matus.kukan at collabora.com
Mon Dec 1 06:14:55 PST 2014


 sax/source/fastparser/fastparser.cxx |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 373daf55d98ba706d3dea131e755da3a00eb259f
Author: Matúš Kukan <matus.kukan at collabora.com>
Date:   Mon Dec 1 13:32:05 2014 +0100

    Add message to exception
    
    Change-Id: I0e7cf850b51343e4afc1ea0a0409ad2c4e596435

diff --git a/sax/source/fastparser/fastparser.cxx b/sax/source/fastparser/fastparser.cxx
index bf3aa01..7e31784 100644
--- a/sax/source/fastparser/fastparser.cxx
+++ b/sax/source/fastparser/fastparser.cxx
@@ -655,7 +655,8 @@ sal_Int32 FastSaxParserImpl::GetTokenWithPrefix( const xmlChar* pPrefix, int nPr
         }
 
         if( !nNamespace )
-            throw SAXException(); // prefix that has no defined namespace url
+            throw SAXException("No namespace defined for " + OUString(XML_CAST(pPrefix),
+                    nPrefixLen, RTL_TEXTENCODING_UTF8), Reference< XInterface >(), Any());
     }
 
     if( nNamespaceToken != FastToken::DONTKNOW )
@@ -688,7 +689,8 @@ OUString FastSaxParserImpl::GetNamespaceURL( const OString& rPrefix ) throw (SAX
                 return rEntity.maNamespaceDefines[nNamespace]->maNamespaceURL;
     }
 
-    throw SAXException(); // prefix that has no defined namespace url
+    throw SAXException("No namespace defined for " + OUString::fromUtf8(rPrefix),
+            Reference< XInterface >(), Any());
 }
 
 sal_Int32 FastSaxParserImpl::GetTokenWithContextNamespace( sal_Int32 nNamespaceToken, const xmlChar* pName, int nNameLen )


More information about the Libreoffice-commits mailing list