summaryrefslogtreecommitdiff
path: root/sot
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-12-20 15:53:21 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-12-21 08:22:29 +0100
commit783120996aba341519393dd0100520707249d208 (patch)
treeaa6ff11749e3880ca7df05010277fde6a6269b45 /sot
parent24158311c115c2db6dd05a751f75a5c084e2c0d1 (diff)
new loplugin: convertlong
merge the droplong and convertuintptr into one new plugin. Limit the analysis to looking at var decl's, since that seems to be safest proposition, even if that too needs some careful analysis. Change-Id: Id005baaf05cfb157ce44a06a1c81f08559a07d1f Reviewed-on: https://gerrit.libreoffice.org/46851 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sot')
-rw-r--r--sot/source/sdstor/storage.cxx8
-rw-r--r--sot/source/sdstor/ucbstorage.cxx10
2 files changed, 9 insertions, 9 deletions
diff --git a/sot/source/sdstor/storage.cxx b/sot/source/sdstor/storage.cxx
index 340b3202b342..be6aa1bf2d36 100644
--- a/sot/source/sdstor/storage.cxx
+++ b/sot/source/sdstor/storage.cxx
@@ -177,9 +177,9 @@ void SotStorageStream::SetSize(sal_uInt64 const nNewSize)
sal_uInt32 SotStorageStream::GetSize() const
{
- sal_uLong nPos = Tell();
+ sal_uInt64 nPos = Tell();
const_cast<SotStorageStream *>(this)->Seek( STREAM_SEEK_TO_END );
- sal_uLong nSize = Tell();
+ sal_uInt64 nSize = Tell();
const_cast<SotStorageStream *>(this)->Seek( nPos );
return nSize;
}
@@ -199,7 +199,7 @@ void SotStorageStream::CopyTo( SotStorageStream * pDestStm )
if( !pOwnStm || !pDestStm->pOwnStm )
{
// If Ole2 or not only own StorageStreams
- sal_uLong nPos = Tell(); // save position
+ sal_uInt64 nPos = Tell(); // save position
Seek( 0 );
pDestStm->SetSize( 0 ); // empty target stream
@@ -497,7 +497,7 @@ bool SotStorage::IsStorageFile( SvStream* pStream )
/** code for new storages must come first! **/
if ( pStream )
{
- long nPos = pStream->Tell();
+ sal_uInt64 nPos = pStream->Tell();
bool bRet = UCBStorage::IsStorageFile( pStream );
if ( !bRet )
bRet = Storage::IsStorageFile( pStream );
diff --git a/sot/source/sdstor/ucbstorage.cxx b/sot/source/sdstor/ucbstorage.cxx
index 6ec64d83ba83..272e65a82fdc 100644
--- a/sot/source/sdstor/ucbstorage.cxx
+++ b/sot/source/sdstor/ucbstorage.cxx
@@ -825,7 +825,7 @@ void UCBStorageStream_Impl::CopySourceToTemporary()
// current position of the temporary stream is not changed
if( m_bSourceRead )
{
- sal_uLong aPos = m_pStream->Tell();
+ sal_uInt64 aPos = m_pStream->Tell();
m_pStream->Seek( STREAM_SEEK_TO_END );
ReadSourceWriteTemporary();
m_pStream->Seek( aPos );
@@ -1010,10 +1010,10 @@ sal_uLong UCBStorageStream_Impl::GetSize()
if( !Init() )
return 0;
- sal_uLong nPos = m_pStream->Tell();
+ sal_uInt64 nPos = m_pStream->Tell();
m_pStream->Seek( STREAM_SEEK_TO_END );
ReadSourceWriteTemporary();
- sal_uLong nRet = m_pStream->Tell();
+ sal_uInt64 nRet = m_pStream->Tell();
m_pStream->Seek( nPos );
return nRet;
@@ -2884,7 +2884,7 @@ bool UCBStorage::IsStorageFile( SvStream* pFile )
if ( !pFile )
return false;
- sal_uLong nPos = pFile->Tell();
+ sal_uInt64 nPos = pFile->Tell();
pFile->Seek( STREAM_SEEK_TO_END );
if ( pFile->Tell() < 4 )
return false;
@@ -2914,7 +2914,7 @@ bool UCBStorage::IsStorageFile( SvStream* pFile )
OUString UCBStorage::GetLinkedFile( SvStream &rStream )
{
OUString aString;
- sal_uLong nPos = rStream.Tell();
+ sal_uInt64 nPos = rStream.Tell();
rStream.Seek( STREAM_SEEK_TO_END );
if ( !rStream.Tell() )
return aString;