diff options
author | Jens-Heiner Rechtien <hr@openoffice.org> | 2006-06-19 22:27:03 +0000 |
---|---|---|
committer | Jens-Heiner Rechtien <hr@openoffice.org> | 2006-06-19 22:27:03 +0000 |
commit | db82b8c6808a60ac0b9260c567f6e52ff21482da (patch) | |
tree | 3fa7e6ac378c1bfe4619753e2e0026409f5f50d9 /configmgr | |
parent | 612025d513ec8c257daf04d4ed1647038fe73c19 (diff) |
INTEGRATION: CWS warnings01 (1.3.6); FILE MERGED
2006/02/14 10:17:35 cd 1.3.6.2: #i55991# Fix warnings for ms c++ compiler
2005/11/10 08:22:09 pl 1.3.6.1: #i53898# removed warnings
Diffstat (limited to 'configmgr')
-rw-r--r-- | configmgr/source/misc/bufferedfile.cxx | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/configmgr/source/misc/bufferedfile.cxx b/configmgr/source/misc/bufferedfile.cxx index 3d6a50ba0c..02426e511f 100644 --- a/configmgr/source/misc/bufferedfile.cxx +++ b/configmgr/source/misc/bufferedfile.cxx @@ -2,9 +2,9 @@ * * $RCSfile: bufferedfile.cxx,v $ * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * - * last change: $Author: rt $ $Date: 2005-10-19 14:44:47 $ + * last change: $Author: hr $ $Date: 2006-06-19 23:27:03 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -75,7 +75,7 @@ BufferedInputFile::RC BufferedInputFile::open( sal_uInt32 uFlags ) // still prevent leaks in case of misuse delete [] m_pBuffer, m_pBuffer = 0; - m_pBuffer = new sal_Int8[theSize]; + m_pBuffer = new sal_Int8[sal::static_int_cast<sal_Int32>(theSize)]; sal_uInt64 nReallyRead = 0; rc = theFile.read(m_pBuffer, theSize, nReallyRead); @@ -156,7 +156,7 @@ BufferedInputFile::RC BufferedInputFile::read( void *pBuffer, sal_uInt64 uBytesR // requested size may be greater than the real file size rBytesRead = std::min(m_nSize - m_nPointer, uBytesRequested); - memcpy(pBuffer, m_pBuffer + m_nPointer, rBytesRead); + memcpy(pBuffer, m_pBuffer + m_nPointer, sal::static_int_cast<sal_Int32>(rBytesRead)); m_nPointer += rBytesRead; } else @@ -243,7 +243,8 @@ BufferedOutputFile::RC BufferedOutputFile::sync() if (written < size) { // but we try our best to stay consistent - m_buffer.erase(m_buffer.begin(),m_buffer.begin()+written); + m_buffer.erase(m_buffer.begin(), + m_buffer.end() + sal::static_int_cast<sal_uInt32>( written )); return E_IO; } |