summaryrefslogtreecommitdiff
path: root/basic/source/runtime
diff options
context:
space:
mode:
Diffstat (limited to 'basic/source/runtime')
-rw-r--r--basic/source/runtime/iosys.cxx22
-rw-r--r--basic/source/runtime/methods.cxx12
2 files changed, 13 insertions, 21 deletions
diff --git a/basic/source/runtime/iosys.cxx b/basic/source/runtime/iosys.cxx
index 36135ee359..59c078710e 100644
--- a/basic/source/runtime/iosys.cxx
+++ b/basic/source/runtime/iosys.cxx
@@ -397,32 +397,25 @@ OslStream::~OslStream()
ULONG OslStream::GetData( void* pData, ULONG nSize )
{
sal_uInt64 nBytesRead = nSize;
- osl::FileBase::RC nRet = osl::FileBase::E_None;
- nRet = maFile.read( pData, nBytesRead, nBytesRead );
+ maFile.read( pData, nBytesRead, nBytesRead );
return (ULONG)nBytesRead;
}
ULONG OslStream::PutData( const void* pData, ULONG nSize )
{
sal_uInt64 nBytesWritten;
- osl::FileBase::RC nRet = osl::FileBase::E_None;
- nRet = maFile.write( pData, (sal_uInt64)nSize, nBytesWritten );
+ maFile.write( pData, (sal_uInt64)nSize, nBytesWritten );
return (ULONG)nBytesWritten;
}
ULONG OslStream::SeekPos( ULONG nPos )
{
- osl::FileBase::RC nRet;
if( nPos == STREAM_SEEK_TO_END )
- {
- nRet = maFile.setPos( Pos_End, 0 );
- }
+ maFile.setPos( Pos_End, 0 );
else
- {
- nRet = maFile.setPos( Pos_Absolut, (sal_uInt64)nPos );
- }
- sal_uInt64 nRealPos;
- nRet = maFile.getPos( nRealPos );
+ maFile.setPos( Pos_Absolut, (sal_uInt64)nPos );
+ sal_uInt64 nRealPos(0);
+ maFile.getPos( nRealPos );
return sal::static_int_cast<ULONG>(nRealPos);
}
@@ -432,8 +425,7 @@ void OslStream::FlushData()
void OslStream::SetSize( ULONG nSize )
{
- osl::FileBase::RC nRet = osl::FileBase::E_None;
- nRet = maFile.setSize( (sal_uInt64)nSize );
+ maFile.setSize( (sal_uInt64)nSize );
}
#endif
diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index f3d03747e8..6ff6418319 100644
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -946,9 +946,9 @@ RTLFUNC(FileLen)
nLen = aStat.GetSize();
#else
DirectoryItem aItem;
- FileBase::RC nRet = DirectoryItem::get( getFullPathUNC( aStr ), aItem );
+ DirectoryItem::get( getFullPathUNC( aStr ), aItem );
FileStatus aFileStatus( FileStatusMask_FileSize );
- nRet = aItem.getFileStatus( aFileStatus );
+ aItem.getFileStatus( aFileStatus );
nLen = (INT32)aFileStatus.getFileSize();
#endif
}
@@ -3112,9 +3112,9 @@ RTLFUNC(GetAttr)
// --> UCB
{
DirectoryItem aItem;
- FileBase::RC nRet = DirectoryItem::get( getFullPathUNC( rPar.Get(1)->GetString() ), aItem );
+ DirectoryItem::get( getFullPathUNC( rPar.Get(1)->GetString() ), aItem );
FileStatus aFileStatus( FileStatusMask_Attributes | FileStatusMask_Type );
- nRet = aItem.getFileStatus( aFileStatus );
+ aItem.getFileStatus( aFileStatus );
sal_uInt64 nAttributes = aFileStatus.getAttributes();
sal_Bool bReadOnly = (nAttributes & Attribute_ReadOnly) != 0;
@@ -3172,9 +3172,9 @@ RTLFUNC(FileDateTime)
aDate = Date( aStat.DateModified() );
#else
DirectoryItem aItem;
- FileBase::RC nRet = DirectoryItem::get( getFullPathUNC( aPath ), aItem );
+ DirectoryItem::get( getFullPathUNC( aPath ), aItem );
FileStatus aFileStatus( FileStatusMask_ModifyTime );
- nRet = aItem.getFileStatus( aFileStatus );
+ aItem.getFileStatus( aFileStatus );
TimeValue aTimeVal = aFileStatus.getModifyTime();
oslDateTime aDT;
osl_getDateTimeFromTimeValue( &aTimeVal, &aDT );