summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2013-11-27 12:52:17 +0100
committerStephan Bergmann <sbergman@redhat.com>2013-11-27 12:52:32 +0100
commita39d07e13495cd06df7169b7778c8d07018794c5 (patch)
treedde67f05acf71fcf181f90bce8dbcc1103e6d400 /tools
parentd8565bd266939b4ae4231f5b2c7d6260bee404e9 (diff)
Unwind occurrences of deprecated sal_sChar, sal_uChar
Change-Id: I76be464200d486efef9c8a7e957c310c9adae3b8
Diffstat (limited to 'tools')
-rw-r--r--tools/source/fsys/urlobj.cxx10
-rw-r--r--tools/source/inet/inetmime.cxx12
-rw-r--r--tools/source/stream/stream.cxx2
3 files changed, 12 insertions, 12 deletions
diff --git a/tools/source/fsys/urlobj.cxx b/tools/source/fsys/urlobj.cxx
index 7cd89ed42f92..e9a05c5abb8a 100644
--- a/tools/source/fsys/urlobj.cxx
+++ b/tools/source/fsys/urlobj.cxx
@@ -2212,16 +2212,16 @@ INetURLObject::PrefixInfo const * INetURLObject::getPrefix(sal_Unicode const *&
if (p >= pEnd)
break;
sal_uInt32 nChar = rtl::toAsciiLowerCase(*p++);
- while (pFirst <= pLast && sal_uChar(pFirst->m_pPrefix[i]) < nChar)
+ while (pFirst <= pLast && static_cast<unsigned char>(pFirst->m_pPrefix[i]) < nChar)
++pFirst;
- while (pFirst <= pLast && sal_uChar(pLast->m_pPrefix[i]) > nChar)
+ while (pFirst <= pLast && static_cast<unsigned char>(pLast->m_pPrefix[i]) > nChar)
--pLast;
}
if (pFirst == pLast)
{
sal_Char const * q = pFirst->m_pPrefix + i;
while (p < pEnd && *q != '\0'
- && rtl::toAsciiLowerCase(*p) == sal_uChar(*q))
+ && rtl::toAsciiLowerCase(*p) == static_cast<unsigned char>(*q))
{
++p;
++q;
@@ -5051,7 +5051,7 @@ sal_uInt32 INetURLObject::getUTF32(sal_Unicode const *& rBegin,
{
int nWeight1;
int nWeight2;
- if (nUTF32 == sal_uChar(cEscapePrefix) && rBegin + 1 < pEnd
+ if (nUTF32 == static_cast<unsigned char>(cEscapePrefix) && rBegin + 1 < pEnd
&& (nWeight1 = INetMIME::getHexWeight(rBegin[0])) >= 0
&& (nWeight2 = INetMIME::getHexWeight(rBegin[1])) >= 0)
{
@@ -5149,7 +5149,7 @@ sal_uInt32 INetURLObject::getUTF32(sal_Unicode const *& rBegin,
{
int nWeight1;
int nWeight2;
- if (nUTF32 == sal_uChar(cEscapePrefix) && rBegin + 1 < pEnd
+ if (nUTF32 == static_cast<unsigned char>(cEscapePrefix) && rBegin + 1 < pEnd
&& ((nWeight1 = INetMIME::getHexWeight(rBegin[0])) >= 0)
&& ((nWeight2 = INetMIME::getHexWeight(rBegin[1])) >= 0))
{
diff --git a/tools/source/inet/inetmime.cxx b/tools/source/inet/inetmime.cxx
index 83ca17e16e65..f0cac3aa6a94 100644
--- a/tools/source/inet/inetmime.cxx
+++ b/tools/source/inet/inetmime.cxx
@@ -181,7 +181,7 @@ void appendISO88591(OUString & rText, sal_Char const * pBegin,
sal_Int32 nLength = pEnd - pBegin;
sal_Unicode * pBuffer = new sal_Unicode[nLength];
for (sal_Unicode * p = pBuffer; pBegin != pEnd;)
- *p++ = sal_uChar(*pBegin++);
+ *p++ = static_cast<unsigned char>(*pBegin++);
rText += OUString(pBuffer, nLength);
delete[] pBuffer;
}
@@ -321,13 +321,13 @@ bool parseParameters(ParameterList const & rInput,
for (sal_Int32 i = 0; i < pNext->m_aValue.getLength(); ++i)
aValue += OUString(sal_Unicode(
sal_Unicode(
- sal_uChar(pNext->m_aValue[i]))
+ static_cast<unsigned char>(pNext->m_aValue[i]))
| 0xF800));
}
else
{
for (sal_Int32 i = 0; i < pNext->m_aValue.getLength(); ++i)
- aValue += OUString( sal_Unicode(sal_uChar(pNext->m_aValue[i])) );
+ aValue += OUString( sal_Unicode(static_cast<unsigned char>(pNext->m_aValue[i])) );
}
pNext = pNext->m_pNext;
if (!pNext || pNext->m_nSection == 0)
@@ -912,7 +912,7 @@ sal_Unicode const * INetMIME::scanParameters(sal_Unicode const * pBegin,
bInvalid = true;
break;
}
- nChar = sal_uChar(*p++);
+ nChar = static_cast<unsigned char>(*p++);
}
else if (nChar == '\\')
{
@@ -3275,7 +3275,7 @@ void INetMIMEEncodedWordOutputSink::finish(bool bWriteTrailer)
nSize = nTargetSize;
for (sal_Size k = 0; k < nTargetSize; ++k)
- if (needsEncodedWordEscape(sal_uChar(
+ if (needsEncodedWordEscape(static_cast<unsigned char>(
pTargetBuffer[k])))
nSize += 2;
}
@@ -3428,7 +3428,7 @@ void INetMIMEEncodedWordOutputSink::finish(bool bWriteTrailer)
{
for (sal_Size k = 0; k < nTargetSize; ++k)
{
- sal_uInt32 nUCS4 = sal_uChar(pTargetBuffer[k]);
+ sal_uInt32 nUCS4 = static_cast<unsigned char>(pTargetBuffer[k]);
bool bEscape = needsEncodedWordEscape(nUCS4);
if (k > 0
&& m_rSink.getColumn() + (bEscape ? 5 : 3)
diff --git a/tools/source/stream/stream.cxx b/tools/source/stream/stream.cxx
index 7cbdca78292b..808008919398 100644
--- a/tools/source/stream/stream.cxx
+++ b/tools/source/stream/stream.cxx
@@ -854,7 +854,7 @@ bool SvStream::StartReadingUnicodeText( rtl_TextEncoding eReadBomCharSet )
}
if (bTryUtf8)
{
- sal_uChar nChar;
+ unsigned char nChar;
nBack += sizeof(nChar);
*this >> nChar;
if (nChar == 0xbf)