summaryrefslogtreecommitdiff
path: root/sax
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2012-03-12 18:26:00 +0100
committerMichael Stahl <mstahl@redhat.com>2012-03-12 18:30:37 +0100
commitb7c79fc2efddc38bea2a459d146c2f80300eb34e (patch)
tree6eeed1f4900d4e7f9c20832d1e56a303ac77b50d /sax
parent7191b52c00b1affbf44c7bf6d4cd43d21ae5e3ce (diff)
sax: replace Min/Max macros with std::max
Diffstat (limited to 'sax')
-rw-r--r--sax/inc/xml2utf.hxx4
-rw-r--r--sax/source/expatwrap/xml2utf.cxx8
2 files changed, 5 insertions, 7 deletions
diff --git a/sax/inc/xml2utf.hxx b/sax/inc/xml2utf.hxx
index 2421442f780f..b22b96a18c5a 100644
--- a/sax/inc/xml2utf.hxx
+++ b/sax/inc/xml2utf.hxx
@@ -29,10 +29,6 @@
#include <sax/dllapi.h>
-// TODO: Woher?
-#define Max( a, b ) (((a)>(b)) ? (a) : (b) )
-#define Min( a, b ) (((a)<(b)) ? (a) : (b) )
-
/*
*
* Text2UnicodeConverter
diff --git a/sax/source/expatwrap/xml2utf.cxx b/sax/source/expatwrap/xml2utf.cxx
index edebc8a8e290..b49d3dc72b0f 100644
--- a/sax/source/expatwrap/xml2utf.cxx
+++ b/sax/source/expatwrap/xml2utf.cxx
@@ -27,12 +27,13 @@
************************************************************************/
#include <string.h>
+#include <algorithm>
+
#include <sal/types.h>
#include <rtl/textenc.h>
#include <rtl/tencinfo.h>
-
#include <com/sun/star/io/XInputStream.hpp>
using namespace ::com::sun::star::uno;
@@ -54,8 +55,9 @@ sal_Int32 XMLFile2UTFConverter::readAndConvert( Sequence<sal_Int8> &seq , sal_In
throw NotConnectedException();
}
if( ! m_bStarted ) {
- nMaxToRead = Max( 512 , nMaxToRead ); // it should be possible to find the encoding attribute
- // within the first 512 bytes == 128 chars in UCS-4
+ // it should be possible to find the encoding attribute
+ // within the first 512 bytes == 128 chars in UCS-4
+ nMaxToRead = ::std::max( 512 , nMaxToRead );
}
sal_Int32 nRead;