summaryrefslogtreecommitdiff
path: root/unotools/source/streaming
diff options
context:
space:
mode:
authorRĂ¼diger Timm <rt@openoffice.org>2004-06-17 12:52:31 +0000
committerRĂ¼diger Timm <rt@openoffice.org>2004-06-17 12:52:31 +0000
commit8ee6651e13e1bab54ef8aead77ed338cb565db23 (patch)
tree7e7a9c1d20c83af09c9e9329ead17c67037d1a86 /unotools/source/streaming
parent454456b5d2c801899246e3163caecfdc3234e9e9 (diff)
INTEGRATION: CWS ooo64bit01 (1.3.140); FILE MERGED
2004/03/31 16:48:57 fa 1.3.140.2: Back out of changes since 2004-03-24, focus on smaller, more integratable changes 2004/03/29 00:30:09 fa 1.3.140.1: More 64-bit changes. 'rsc' still broken, but not as much as before.
Diffstat (limited to 'unotools/source/streaming')
-rw-r--r--unotools/source/streaming/streamhelper.cxx14
1 files changed, 8 insertions, 6 deletions
diff --git a/unotools/source/streaming/streamhelper.cxx b/unotools/source/streaming/streamhelper.cxx
index 140c46f6806c..5170d5392fe0 100644
--- a/unotools/source/streaming/streamhelper.cxx
+++ b/unotools/source/streaming/streamhelper.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: streamhelper.cxx,v $
*
- * $Revision: 1.3 $
+ * $Revision: 1.4 $
*
- * last change: $Author: hr $ $Date: 2001-09-27 11:17:08 $
+ * last change: $Author: rt $ $Date: 2004-06-17 13:52:31 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -91,9 +91,10 @@ sal_Int32 SAL_CALL OInputStreamHelper::readBytes(staruno::Sequence< sal_Int8 >&
::osl::MutexGuard aGuard( m_aMutex );
aData.realloc(nBytesToRead);
- sal_uInt32 nRead;
+ sal_Size nRead;
ErrCode nError = m_xLockBytes->ReadAt(m_nActPos, (void*)aData.getArray(), nBytesToRead, &nRead);
- m_nActPos += nRead;
+ // FIXME nRead could be truncated on 64-bit arches
+ m_nActPos += (sal_uInt32)nRead;
if (nError != ERRCODE_NONE)
throw stario::IOException(::rtl::OUString(), static_cast<staruno::XWeak*>(this));
@@ -193,9 +194,10 @@ void SAL_CALL OOutputStreamHelper::writeBytes(const staruno::Sequence< sal_Int8
if (!m_xLockBytes.Is())
throw stario::NotConnectedException(::rtl::OUString(), static_cast<staruno::XWeak*>(this));
- ULONG nWritten;
+ sal_Size nWritten;
ErrCode nError = m_xLockBytes->WriteAt( m_nActPos, aData.getConstArray(), aData.getLength(), &nWritten );
- m_nActPos += nWritten;
+ // FIXME nWritten could be truncated on 64-bit arches
+ m_nActPos += (sal_uInt32)nWritten;
if (nError != ERRCODE_NONE ||
nWritten != aData.getLength())