include/svtools/imap.hxx          |    4 ++--
 include/svtools/svparser.hxx      |    2 +-
 svtools/source/misc/imap2.cxx     |    2 +-
 svtools/source/misc/imap3.cxx     |    4 ++--
 svtools/source/svhtml/parhtml.cxx |   22 +++++++++++-----------
 svtools/source/svrtf/svparser.cxx |    2 +-
 svtools/source/urlobj/inetimg.cxx |    3 ++-
 7 files changed, 20 insertions(+), 19 deletions(-)

New commits:
commit 05d3a1899eb50202fd3929b702bae1003b5610be
Author: Jochen Nitschke <j.nitschke+loger...@ok.de>
Date:   Thu May 11 15:53:08 2017 +0200

    tdf#75280 replace uses of sal_uLong
    
    those vars get their type from SvStream which uses sal_uInt64
    
    Change-Id: Ia356699bb0f5e9787ae6f02e52e0b00cc2f817b1
    Reviewed-on: https://gerrit.libreoffice.org/37547
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>

diff --git a/include/svtools/imap.hxx b/include/svtools/imap.hxx
index ecb5b09edfc1..0b30c6183596 100644
--- a/include/svtools/imap.hxx
+++ b/include/svtools/imap.hxx
@@ -118,8 +118,8 @@ public:
 class IMapCompat
 {
     SvStream*       pRWStm;
-    sal_uLong       nCompatPos;
-    sal_uLong       nTotalSize;
+    sal_uInt64      nCompatPos;
+    sal_uInt64      nTotalSize;
     StreamMode      nStmMode;
 
                     IMapCompat( const IMapCompat& ) = delete;
diff --git a/include/svtools/svparser.hxx b/include/svtools/svparser.hxx
index 136eb3a42573..2faa184d7643 100644
--- a/include/svtools/svparser.hxx
+++ b/include/svtools/svparser.hxx
@@ -60,7 +60,7 @@ protected:
 
     rtl_TextEncoding    eSrcEnc;            // Source encoding
 
-    sal_uLong           nNextChPos;
+    sal_uInt64          nNextChPos;
     sal_uInt32          nNextCh;            // current character codepoint in 
UTF32 for the "lex"
 
     bool                bUCS2BSrcEnc : 1;   // or as big-endian UCS2
diff --git a/svtools/source/misc/imap2.cxx b/svtools/source/misc/imap2.cxx
index e9ccd365606d..e60174de0dab 100644
--- a/svtools/source/misc/imap2.cxx
+++ b/svtools/source/misc/imap2.cxx
@@ -501,7 +501,7 @@ Point ImageMap::ImpReadNCSACoords( const char** ppStr )
 
 sal_uLong ImageMap::ImpDetectFormat( SvStream& rIStm )
 {
-    sal_uLong   nPos = rIStm.Tell();
+    sal_uInt64  nPos = rIStm.Tell();
     sal_uLong   nRet = IMAP_FORMAT_BIN;
     char    cMagic[6];
 
diff --git a/svtools/source/misc/imap3.cxx b/svtools/source/misc/imap3.cxx
index 49e8dd9b4aba..cef90050650d 100644
--- a/svtools/source/misc/imap3.cxx
+++ b/svtools/source/misc/imap3.cxx
@@ -67,7 +67,7 @@ IMapCompat::~IMapCompat()
     {
         if ( nStmMode == StreamMode::WRITE )
         {
-            const sal_uLong nEndPos = pRWStm->Tell();
+            const sal_uInt64 nEndPos = pRWStm->Tell();
 
             pRWStm->Seek( nCompatPos );
             pRWStm->WriteUInt32( nEndPos - nTotalSize );
@@ -75,7 +75,7 @@ IMapCompat::~IMapCompat()
         }
         else
         {
-            const sal_uLong nReadSize = pRWStm->Tell() - nCompatPos;
+            const sal_uInt64 nReadSize = pRWStm->Tell() - nCompatPos;
 
             if ( nTotalSize > nReadSize )
                 pRWStm->SeekRel( nTotalSize - nReadSize );
diff --git a/svtools/source/svhtml/parhtml.cxx 
b/svtools/source/svhtml/parhtml.cxx
index f7daee079cb1..aaee085dd267 100644
--- a/svtools/source/svhtml/parhtml.cxx
+++ b/svtools/source/svhtml/parhtml.cxx
@@ -374,7 +374,7 @@ HtmlTokenId HTMLParser::ScanText( const sal_Unicode cBreak )
                 sTmpBuffer.append( '&' );
             else
             {
-                sal_uLong nStreamPos = rInput.Tell();
+                sal_uInt64 nStreamPos = rInput.Tell();
                 sal_uLong nLinePos = GetLinePos();
 
                 sal_uInt32 cChar = 0U;
@@ -459,7 +459,7 @@ HtmlTokenId HTMLParser::ScanText( const sal_Unicode cBreak )
                         if( 0U == cChar && ';' != nNextCh )
                         {
                             DBG_ASSERT( rInput.Tell() - nStreamPos ==
-                                        (sal_uLong)(nPos+1L)*GetCharSize(),
+                                        
static_cast<sal_uInt64>(nPos+1)*GetCharSize(),
                                         "UTF-8 is failing here" );
                             for( sal_Int32 i = nPos-1; i>1; i-- )
                             {
@@ -469,8 +469,8 @@ HtmlTokenId HTMLParser::ScanText( const sal_Unicode cBreak )
                                 cChar = GetHTMLCharName( sEntity );
                                 if( cChar )
                                 {
-                                    rInput.SeekRel( -(long)
-                                            ((nPos-i)*GetCharSize()) );
+                                    rInput.SeekRel( -static_cast<sal_Int64>
+                                            (nPos-i)*GetCharSize() );
                                     nlLinePos -= sal_uInt32(nPos-i);
                                     nPos = i;
                                     ClearTxtConvContext();
@@ -486,7 +486,7 @@ HtmlTokenId HTMLParser::ScanText( const sal_Unicode cBreak )
                             sTmpBuffer.append( '&' );
 
                             DBG_ASSERT( rInput.Tell()-nStreamPos ==
-                                        (sal_uLong)(nPos+1)*GetCharSize(),
+                                        
static_cast<sal_uInt64>(nPos+1)*GetCharSize(),
                                         "Wrong stream position" );
                             DBG_ASSERT( nlLinePos-nLinePos ==
                                         (sal_uLong)(nPos+1),
@@ -523,7 +523,7 @@ HtmlTokenId HTMLParser::ScanText( const sal_Unicode cBreak )
                                     // restart with character
                                     nNextCh = '&';
                                     DBG_ASSERT( rInput.Tell()-nStreamPos ==
-                                                
(sal_uLong)(nPos+1)*GetCharSize(),
+                                                
static_cast<sal_uInt64>(nPos+1)*GetCharSize(),
                                                 "Wrong stream position" );
                                     DBG_ASSERT( nlLinePos-nLinePos ==
                                                 (sal_uLong)(nPos+1),
@@ -584,7 +584,7 @@ HtmlTokenId HTMLParser::ScanText( const sal_Unicode cBreak )
                         // during the next execution a new character is read.
                         // Thus we have to position in front of the '&'.
                         nNextCh = 0U;
-                        rInput.Seek( nStreamPos-(sal_uInt32)GetCharSize() );
+                        rInput.Seek( nStreamPos - GetCharSize() );
                         nlLinePos = nLinePos-1;
                         ClearTxtConvContext();
                         bReadNextChar = true;
@@ -787,7 +787,7 @@ HtmlTokenId HTMLParser::GetNextRawToken()
                 aToken += sTmpBuffer.makeStringAndClear();
 
                 // and remember position in stream.
-                sal_uLong nStreamPos = rInput.Tell();
+                sal_uInt64 nStreamPos = rInput.Tell();
                 sal_uLong nLineNr = GetLineNr();
                 sal_uLong nLinePos = GetLinePos();
 
@@ -1017,7 +1017,7 @@ HtmlTokenId HTMLParser::GetNextToken_()
         {
         case '<':
             {
-                sal_uLong nStreamPos = rInput.Tell();
+                sal_uInt64 nStreamPos = rInput.Tell();
                 sal_uLong nLineNr = GetLineNr();
                 sal_uLong nLinePos = GetLinePos();
 
@@ -1082,7 +1082,7 @@ HtmlTokenId HTMLParser::GetNextToken_()
                         aToken = sSaveToken;
                         if( '>'!=nNextCh )
                             aToken += " ";
-                        sal_uLong nCStreamPos = 0;
+                        sal_uInt64 nCStreamPos = 0;
                         sal_uLong nCLineNr = 0;
                         sal_uLong nCLinePos = 0;
                         sal_Int32 nCStrLen = 0;
@@ -1187,7 +1187,7 @@ HtmlTokenId HTMLParser::GetNextToken_()
                     {
                         nRet = HtmlTokenId::UNKNOWNCONTROL_ON;
 
-                        sal_uLong nCStreamPos = rInput.Tell();
+                        sal_uInt64 nCStreamPos = rInput.Tell();
                         sal_uLong nCLineNr = GetLineNr(), nCLinePos = 
GetLinePos();
 
                         bool bDone = false;
diff --git a/svtools/source/svrtf/svparser.cxx 
b/svtools/source/svrtf/svparser.cxx
index 789464ddbdf5..947ef75a98f3 100644
--- a/svtools/source/svrtf/svparser.cxx
+++ b/svtools/source/svrtf/svparser.cxx
@@ -32,7 +32,7 @@ template<typename T>
 struct SvParser_Impl
 {
     OUString        aToken;             // gescanntes Token
-    sal_uLong       nFilePos;           // actual position in stream
+    sal_uInt64      nFilePos;           // actual position in stream
     sal_uLong       nlLineNr;           // actual line number
     sal_uLong       nlLinePos;          // actual column number
     long            nTokenValue;        // extra value (RTF)
diff --git a/svtools/source/urlobj/inetimg.cxx 
b/svtools/source/urlobj/inetimg.cxx
index df3f7a210970..0abae28c90dd 100644
--- a/svtools/source/urlobj/inetimg.cxx
+++ b/svtools/source/urlobj/inetimg.cxx
@@ -94,7 +94,8 @@ bool INetImage::Read( SvStream& rIStm, SotClipboardFormatId 
nFormat )
     sal_Char pImageURL[1];      // Append all variable-length strings starting 
here
 */
             rtl_TextEncoding eSysCSet = osl_getThreadTextEncoding();
-            sal_Int32 nVal, nAnchorOffset, nAltOffset, nFilePos;
+            sal_Int32 nVal, nAnchorOffset, nAltOffset;
+            sal_uInt64 nFilePos;
 
             nFilePos = rIStm.Tell();
             // skip over iSize (int), bIsMao ( sal_Bool ) alignment of 4 !!!!
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to