summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2016-09-14 19:47:52 +0200
committerMichael Stahl <mstahl@redhat.com>2016-09-15 12:01:12 +0200
commitab7d6b0d4fa8c91306f7b4f460a4596abc159912 (patch)
treebc6d15b4e79fcf42a5ed3c86b8267f49ea7f3e3a /tools
parentb647996a9babbee7b33cf45192e57df6a124628b (diff)
tools: SvFileStream::LockRange/UnlockRange take 64 bit positions
Change-Id: I85d9cc00daaaa127817aaaa6f54d3e6f86907fb6
Diffstat (limited to 'tools')
-rw-r--r--tools/source/stream/strmunx.cxx18
-rw-r--r--tools/source/stream/strmwnt.cxx4
2 files changed, 11 insertions, 11 deletions
diff --git a/tools/source/stream/strmunx.cxx b/tools/source/stream/strmunx.cxx
index 36ed303b81cc..66a5e1a77b18 100644
--- a/tools/source/stream/strmunx.cxx
+++ b/tools/source/stream/strmunx.cxx
@@ -48,20 +48,20 @@ struct LockMutex : public rtl::Static< osl::Mutex, LockMutex > {};
struct InternalStreamLock
{
- std::size_t m_nStartPos;
- std::size_t m_nEndPos;
+ sal_uInt64 m_nStartPos;
+ sal_uInt64 m_nEndPos;
SvFileStream* m_pStream;
osl::DirectoryItem m_aItem;
- InternalStreamLock( std::size_t, std::size_t, SvFileStream* );
+ InternalStreamLock( sal_uInt64, sal_uInt64, SvFileStream* );
~InternalStreamLock();
};
struct LockList : public rtl::Static< std::vector<InternalStreamLock>, LockList > {};
InternalStreamLock::InternalStreamLock(
- std::size_t nStart,
- std::size_t nEnd,
+ sal_uInt64 const nStart,
+ sal_uInt64 const nEnd,
SvFileStream* pStream ) :
m_nStartPos( nStart ),
m_nEndPos( nEnd ),
@@ -90,7 +90,7 @@ InternalStreamLock::~InternalStreamLock()
#endif
}
-bool lockFile( std::size_t nStart, std::size_t nEnd, SvFileStream* pStream )
+bool lockFile( sal_uInt64 const nStart, sal_uInt64 const nEnd, SvFileStream* pStream )
{
osl::DirectoryItem aItem;
if (osl::DirectoryItem::get( pStream->GetFileName(), aItem) != osl::FileBase::E_None )
@@ -145,7 +145,7 @@ bool lockFile( std::size_t nStart, std::size_t nEnd, SvFileStream* pStream )
return true;
}
-void unlockFile( std::size_t nStart, std::size_t nEnd, SvFileStream const * pStream )
+void unlockFile( sal_uInt64 const nStart, sal_uInt64 const nEnd, SvFileStream const * pStream )
{
osl::MutexGuard aGuard( LockMutex::get() );
std::vector<InternalStreamLock> &rLockList = LockList::get();
@@ -379,7 +379,7 @@ void SvFileStream::FlushData()
// does not exist locally
}
-bool SvFileStream::LockRange( std::size_t nByteOffset, std::size_t nBytes )
+bool SvFileStream::LockRange(sal_uInt64 const nByteOffset, std::size_t nBytes)
{
int nLockMode = 0;
@@ -428,7 +428,7 @@ bool SvFileStream::LockRange( std::size_t nByteOffset, std::size_t nBytes )
return true;
}
-bool SvFileStream::UnlockRange( std::size_t nByteOffset, std::size_t nBytes )
+bool SvFileStream::UnlockRange(sal_uInt64 const nByteOffset, std::size_t nBytes)
{
if ( ! IsOpen() )
return false;
diff --git a/tools/source/stream/strmwnt.cxx b/tools/source/stream/strmwnt.cxx
index 22c10665211a..627471c64edf 100644
--- a/tools/source/stream/strmwnt.cxx
+++ b/tools/source/stream/strmwnt.cxx
@@ -192,7 +192,7 @@ void SvFileStream::FlushData()
}
}
-bool SvFileStream::LockRange( std::size_t nByteOffset, std::size_t nBytes )
+bool SvFileStream::LockRange(sal_uInt64 const nByteOffset, std::size_t nBytes)
{
bool bRetVal = false;
if( IsOpen() )
@@ -204,7 +204,7 @@ bool SvFileStream::LockRange( std::size_t nByteOffset, std::size_t nBytes )
return bRetVal;
}
-bool SvFileStream::UnlockRange( std::size_t nByteOffset, std::size_t nBytes )
+bool SvFileStream::UnlockRange(sal_uInt64 const nByteOffset, std::size_t nBytes)
{
bool bRetVal = false;
if( IsOpen() )