diff options
Diffstat (limited to 'tools')
-rw-r--r-- | tools/inc/tools/string.hxx | 4 | ||||
-rw-r--r-- | tools/source/string/tustring.cxx | 8 |
2 files changed, 6 insertions, 6 deletions
diff --git a/tools/inc/tools/string.hxx b/tools/inc/tools/string.hxx index 6be3d7db5709..1c73fe4fb230 100644 --- a/tools/inc/tools/string.hxx +++ b/tools/inc/tools/string.hxx @@ -274,7 +274,7 @@ public: void SetToken( xub_StrLen nToken, sal_Unicode cTok, const UniString& rStr, xub_StrLen nIndex = 0 ); - UniString GetToken( xub_StrLen nToken, sal_Unicode cTok, xub_StrLen& rIndex ) const; + UniString GetToken( xub_StrLen nToken, sal_Unicode cTok, sal_Int32& rIndex ) const; UniString GetToken( xub_StrLen nToken, sal_Unicode cTok = ';' ) const; const sal_Unicode* GetBuffer() const { return mpData->maStr; } @@ -303,7 +303,7 @@ inline UniString UniString::Copy( xub_StrLen nIndex, xub_StrLen nCount ) const inline UniString UniString::GetToken( xub_StrLen nToken, sal_Unicode cTok ) const { - xub_StrLen nTempPos = 0; + sal_Int32 nTempPos = 0; return GetToken( nToken, cTok, nTempPos ); } diff --git a/tools/source/string/tustring.cxx b/tools/source/string/tustring.cxx index a66dc6026452..b07cd3c9e8d8 100644 --- a/tools/source/string/tustring.cxx +++ b/tools/source/string/tustring.cxx @@ -520,14 +520,14 @@ void STRING::SetToken( xub_StrLen nToken, STRCODE cTok, const STRING& rStr, Replace( nFirstChar, i-nFirstChar, rStr ); } -STRING STRING::GetToken( xub_StrLen nToken, STRCODE cTok, xub_StrLen& rIndex ) const +STRING STRING::GetToken( xub_StrLen nToken, STRCODE cTok, sal_Int32& rIndex ) const { DBG_CHKTHIS( STRING, DBGCHECKSTRING ); const STRCODE* pStr = mpData->maStr; xub_StrLen nLen = (xub_StrLen)mpData->mnLen; xub_StrLen nTok = 0; - xub_StrLen nFirstChar = rIndex; + sal_Int32 nFirstChar = rIndex; xub_StrLen i = nFirstChar; // Determine token position and length @@ -557,12 +557,12 @@ STRING STRING::GetToken( xub_StrLen nToken, STRCODE cTok, xub_StrLen& rIndex ) c if ( i < nLen ) rIndex = i+1; else - rIndex = STRING_NOTFOUND; + rIndex = -1; return Copy( nFirstChar, i-nFirstChar ); } else { - rIndex = STRING_NOTFOUND; + rIndex = -1; return STRING(); } } |