dbertoni 02/05/08 18:26:18
Modified: c/src/XalanDOM XalanDOMString.cpp
Log:
Fixed problems with doXercesTranscode().
Revision Changes Path
1.24 +9 -12 xml-xalan/c/src/XalanDOM/XalanDOMString.cpp
Index: XalanDOMString.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XalanDOM/XalanDOMString.cpp,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- XalanDOMString.cpp 8 May 2002 23:07:00 -0000 1.23
+++ XalanDOMString.cpp 9 May 2002 01:26:18 -0000 1.24
@@ -749,40 +749,39 @@
-#include <util/XMLString.hpp>
+#include <xercesc/util/XMLString.hpp>
-template <class SourceType, class TargetType, class SizeType, class
LengthFunctionType>
+template <class SourceType, class TargetType>
bool
doXercesTranscode(
const SourceType* theSourceString,
- SizeType
theSourceStringLength,
+ XalanDOMString::size_type theSourceStringLength,
bool
theSourceStringIsNullTerminated,
#if defined(XALAN_NO_NAMESPACES)
vector<TargetType>& theTargetVector,
#else
std::vector<TargetType>& theTargetVector,
#endif
- bool
terminate,
- LengthFunctionType
theLengthFunction)
+ bool
terminate)
{
const SourceType* theRealSourceString = theSourceString;
- SizeType theRealSourceStringLength =
theSourceStringLength;
+ XalanDOMString::size_type theRealSourceStringLength =
theSourceStringLength;
XalanArrayAutoPtr<SourceType> theGuard;
if (theSourceStringIsNullTerminated == true)
{
- theRealSourceStringLength = theLengthFunction(theSourceString);
+ theRealSourceStringLength =
XalanDOMString::length(theSourceString);
}
else
{
theGuard.reset(new SourceType[theRealSourceStringLength + 1]);
assert(theGuard.get() != 0);
- for (SizeType index = 0; index < theRealSourceStringLength;
++index)
+ for (XalanDOMString::size_type index = 0; index <
theRealSourceStringLength; ++index)
{
theGuard[index] = theSourceString[index];
}
@@ -881,8 +880,7 @@
theSourceStringLength,
theSourceStringIsNullTerminated,
theTargetVector,
- terminate,
- length);
+ terminate);
}
#else
const wchar_t* theTempSource = 0;
@@ -1014,8 +1012,7 @@
theSourceStringLength,
theSourceStringIsNullTerminated,
theTargetVector,
- terminate,
- length);
+ terminate);
}
#else
XalanArrayAutoPtr<char> tempString;
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]