summaryrefslogtreecommitdiff
path: root/sax
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2015-09-28 23:14:53 +0200
committerMichael Stahl <mstahl@redhat.com>2015-09-29 14:57:40 +0200
commit54bb97aa30d29865bf4b9826db7c7ec0607e7992 (patch)
tree71408a7de05696e8b3c994e9d34509c84adfcc72 /sax
parent810257500200391de71c8591ce24b8a942249bd5 (diff)
sax: remove obsolete XML_UNICODE code
Change-Id: Ib5b9b7dc01b713554cf33f58f8fe2f97cb32c369
Diffstat (limited to 'sax')
-rw-r--r--sax/source/expatwrap/sax_expat.cxx40
1 files changed, 0 insertions, 40 deletions
diff --git a/sax/source/expatwrap/sax_expat.cxx b/sax/source/expatwrap/sax_expat.cxx
index c02ee87bbad1..51c997ffc91f 100644
--- a/sax/source/expatwrap/sax_expat.cxx
+++ b/sax/source/expatwrap/sax_expat.cxx
@@ -18,7 +18,6 @@
*/
#include <stdlib.h>
#include <string.h>
-#include <sal/alloca.h>
#include <cassert>
#include <vector>
@@ -53,47 +52,8 @@ using namespace ::com::sun::star::io;
namespace {
-// Useful macros for correct String conversion depending on the chosen expat-mode
-#ifdef XML_UNICODE
-OUString XmlNChar2OUString( const XML_Char *p , int nLen )
-{
- if( p ) {
- if( sizeof( sal_Unicode ) == sizeof( XML_Char ) )
- {
- return OUString( (sal_Unicode*)p,nLen);
- }
- else
- {
- sal_Unicode *pWchar = (sal_Unicode *)alloca( sizeof( sal_Unicode ) * nLen );
- for( int n = 0 ; n < nLen ; n++ ) {
- pWchar[n] = (sal_Unicode) p[n];
- }
- return OUString( pWchar , nLen );
- }
- }
- else {
- return OUString();
- }
-}
-
-OUString XmlChar2OUString( const XML_Char *p )
-{
- if( p ) {
- int nLen;
- for( nLen = 0 ; p[nLen] ; nLen ++ )
- ;
- return XmlNChar2OUString( p , nLen );
- }
- else return OUString();
-}
-
-
-#define XML_CHAR_TO_OUSTRING(x) XmlChar2OUString(x)
-#define XML_CHAR_N_TO_USTRING(x,n) XmlNChar2OUString(x,n)
-#else
#define XML_CHAR_TO_OUSTRING(x) OUString(x , strlen( x ), RTL_TEXTENCODING_UTF8)
#define XML_CHAR_N_TO_USTRING(x,n) OUString(x,n, RTL_TEXTENCODING_UTF8 )
-#endif
/*