diff options
author | Caolán McNamara <caolanm@redhat.com> | 2011-04-11 21:19:54 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2011-04-11 21:41:57 +0100 |
commit | d2a1c2d4cfa51b6ee8a7f38baa258633fae9ec6d (patch) | |
tree | ab712bc1a814bfc15def9990df0896436f346628 /lotuswordpro/source/filter/lwpobjhdr.cxx | |
parent | not useful dates in source code removed (diff) | |
download | core-d2a1c2d4cfa51b6ee8a7f38baa258633fae9ec6d.tar.gz core-d2a1c2d4cfa51b6ee8a7f38baa258633fae9ec6d.zip |
fix what there is to fix
Diffstat (limited to 'lotuswordpro/source/filter/lwpobjhdr.cxx')
-rw-r--r-- | lotuswordpro/source/filter/lwpobjhdr.cxx | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lotuswordpro/source/filter/lwpobjhdr.cxx b/lotuswordpro/source/filter/lwpobjhdr.cxx index 271ee9babb84..ef6e253067d1 100644 --- a/lotuswordpro/source/filter/lwpobjhdr.cxx +++ b/lotuswordpro/source/filter/lwpobjhdr.cxx @@ -74,9 +74,8 @@ LwpObjectHeader::LwpObjectHeader() /** * @descr read header from stream */ -void LwpObjectHeader::Read(LwpSvStream &rStrm) +bool LwpObjectHeader::Read(LwpSvStream &rStrm) { - sal_uInt8 nFlagBits = 0; sal_uInt32 nVersionID = 0; sal_uInt32 nRefCount = 0; @@ -84,6 +83,8 @@ void LwpObjectHeader::Read(LwpSvStream &rStrm) sal_uInt32 nNextVersionID = 0; sal_uInt32 nHeaderSize = 0; + sal_Int64 nStartPos = rStrm.Tell(); + if ( LwpFileHeader::m_nFileRevision < 0x000B) { rStrm.Read(&m_nTag, sizeof(m_nTag)); @@ -196,6 +197,8 @@ void LwpObjectHeader::Read(LwpSvStream &rStrm) m_bCompressed = sal_True; } } + sal_Int64 nEndPos = rStrm.Tell(); + return (nStartPos + nHeaderSize == nEndPos); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |