summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
Diffstat (limited to 'sd')
-rw-r--r--sd/source/filter/eppt/eppt.cxx3
-rw-r--r--sd/source/filter/eppt/epptso.cxx3
-rw-r--r--sd/source/filter/eppt/escherex.cxx3
-rw-r--r--sd/source/filter/ppt/pptatom.cxx5
-rw-r--r--sd/source/filter/ppt/propread.cxx5
-rw-r--r--sd/source/ui/app/sdxfer.cxx2
-rw-r--r--sd/source/ui/unoidl/UnoDocumentSettings.cxx8
7 files changed, 8 insertions, 21 deletions
diff --git a/sd/source/filter/eppt/eppt.cxx b/sd/source/filter/eppt/eppt.cxx
index 230797458c05..ca8ee466efae 100644
--- a/sd/source/filter/eppt/eppt.cxx
+++ b/sd/source/filter/eppt/eppt.cxx
@@ -1232,8 +1232,7 @@ void PPTWriter::ImplWriteVBA()
{
if ( mpVBA )
{
- mpVBA->Seek( STREAM_SEEK_TO_END );
- sal_uInt32 nLen = mpVBA->Tell();
+ sal_uInt32 nLen = mpVBA->TellEnd();
if ( nLen > 8 )
{
nLen -= 8;
diff --git a/sd/source/filter/eppt/epptso.cxx b/sd/source/filter/eppt/epptso.cxx
index f5df6e331b8a..bcda24246ef6 100644
--- a/sd/source/filter/eppt/epptso.cxx
+++ b/sd/source/filter/eppt/epptso.cxx
@@ -432,8 +432,7 @@ bool PPTWriter::ImplCloseDocument()
}
}
- mpExEmbed->Seek( STREAM_SEEK_TO_END );
- sal_uInt32 nExEmbedSize = mpExEmbed->Tell();
+ sal_uInt32 nExEmbedSize = mpExEmbed->TellEnd();
// nEnvironment : whole size of the environment container
sal_uInt32 nEnvironment = maFontCollection.GetCount() * 76 // 68 bytes per Fontenityatom and 8 Bytes per header
diff --git a/sd/source/filter/eppt/escherex.cxx b/sd/source/filter/eppt/escherex.cxx
index d0894bd02216..f0929c10da1d 100644
--- a/sd/source/filter/eppt/escherex.cxx
+++ b/sd/source/filter/eppt/escherex.cxx
@@ -249,8 +249,7 @@ sal_uInt32 PptEscherEx::EnterGroup( ::tools::Rectangle const * pBoundRect, SvMem
}
if ( pClientData )
{
- pClientData->Seek( STREAM_SEEK_TO_END );
- sal_uInt32 nSize = pClientData->Tell();
+ sal_uInt32 nSize = pClientData->TellEnd();
if ( nSize )
{
mpOutStrm->WriteUInt32( ( ESCHER_ClientData << 16 ) | 0xf )
diff --git a/sd/source/filter/ppt/pptatom.cxx b/sd/source/filter/ppt/pptatom.cxx
index 1a6bd6957305..90e61e738ffb 100644
--- a/sd/source/filter/ppt/pptatom.cxx
+++ b/sd/source/filter/ppt/pptatom.cxx
@@ -37,10 +37,7 @@ Atom::Atom( const DffRecordHeader& rRecordHeader, SvStream& rStream )
Atom* pLastAtom = nullptr;
// retrieve file size (to allow sanity checks)
- sal_uInt64 const nStreamPos = mrStream.Tell();
- mrStream.Seek( STREAM_SEEK_TO_END );
- sal_uInt64 const nStreamSize = mrStream.Tell();
- mrStream.Seek( nStreamPos );
+ sal_uInt64 const nStreamSize = mrStream.TellEnd();
while( (mrStream.GetError() == ERRCODE_NONE )
&& ( mrStream.Tell() < nStreamSize )
diff --git a/sd/source/filter/ppt/propread.cxx b/sd/source/filter/ppt/propread.cxx
index 4c1248b08234..112d8a0befe8 100644
--- a/sd/source/filter/ppt/propread.cxx
+++ b/sd/source/filter/ppt/propread.cxx
@@ -195,10 +195,7 @@ PropItem& PropItem::operator=( PropItem& rPropItem )
delete[] static_cast<sal_uInt8*>(SwitchBuffer());
mnTextEnc = rPropItem.mnTextEnc;
- sal_uInt32 nItemPos = rPropItem.Tell();
- rPropItem.Seek( STREAM_SEEK_TO_END );
- SvMemoryStream::WriteBytes(rPropItem.GetData(), rPropItem.Tell());
- rPropItem.Seek( nItemPos );
+ SvMemoryStream::WriteBytes(rPropItem.GetData(), rPropItem.TellEnd());
}
return *this;
}
diff --git a/sd/source/ui/app/sdxfer.cxx b/sd/source/ui/app/sdxfer.cxx
index 90d651c257b5..2a7dadaf9118 100644
--- a/sd/source/ui/app/sdxfer.cxx
+++ b/sd/source/ui/app/sdxfer.cxx
@@ -827,7 +827,7 @@ bool SdTransferable::SetTableRTF( SdDrawDocument* pModel )
{
SvMemoryStream aMemStm( 65535, 65535 );
sdr::table::SdrTableObj::ExportAsRTF( aMemStm, *pTableObj );
- return SetAny( Any( Sequence< sal_Int8 >( static_cast< const sal_Int8* >( aMemStm.GetData() ), aMemStm.Seek( STREAM_SEEK_TO_END ) ) ) );
+ return SetAny( Any( Sequence< sal_Int8 >( static_cast< const sal_Int8* >( aMemStm.GetData() ), aMemStm.TellEnd() ) ) );
}
}
}
diff --git a/sd/source/ui/unoidl/UnoDocumentSettings.cxx b/sd/source/ui/unoidl/UnoDocumentSettings.cxx
index 5eec0ffda4c3..dbb565de0ec9 100644
--- a/sd/source/ui/unoidl/UnoDocumentSettings.cxx
+++ b/sd/source/ui/unoidl/UnoDocumentSettings.cxx
@@ -1199,12 +1199,8 @@ DocumentSettings::_getPropertyValues(
{
SvMemoryStream aStream;
pTempPrinter->Store( aStream );
- aStream.Seek ( STREAM_SEEK_TO_END );
- sal_uInt32 nSize = aStream.Tell();
- aStream.Seek ( STREAM_SEEK_TO_BEGIN );
- Sequence < sal_Int8 > aSequence ( nSize );
- memcpy ( aSequence.getArray(), aStream.GetData(), nSize );
- *pValue <<= aSequence;
+ *pValue <<= Sequence< sal_Int8 >( static_cast< const sal_Int8* >( aStream.GetData() ),
+ aStream.TellEnd() );
}
else
{