| author | Luboš Luňák <l.lunak@suse.cz> | 2011-05-02 09:21:15 (GMT) |
|---|---|---|
| committer | Luboš Luňák <l.lunak@suse.cz> | 2011-05-02 09:29:32 (GMT) |
| commit | ba678b7d44fbde9e9ac1f0e01b49dc0b211530c0 (patch) (side-by-side diff) | |
| tree | 3303d3c26f5a391199ab4668be7b9431c320017a | |
| parent | 18211731500d267bd68c914d2cf204d8e9ee755f (diff) | |
| download | libs-gui-ba678b7d44fbde9e9ac1f0e01b49dc0b211530c0.zip libs-gui-ba678b7d44fbde9e9ac1f0e01b49dc0b211530c0.tar.gz | |
fix off-by-one when exporting postscript fonts to pdf
The problem shows when exporting a text document to pdf and there
a .pfb font is used (e.g. Standard Symbols L or Bitstream Charter).
As far as I can say this is actually harmless, as this is just
a padding section, but Acroread shows an error dialog for this
(bnc#690005).
| -rw-r--r-- | vcl/source/gdi/pdfwriter_impl.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx index 485dad3..91c4f32 100644 --- a/vcl/source/gdi/pdfwriter_impl.cxx +++ b/vcl/source/gdi/pdfwriter_impl.cxx @@ -3359,9 +3359,9 @@ std::map< sal_Int32, sal_Int32 > PDFWriterImpl::emitEmbeddedFont( const ImplFont throw FontException(); // nLength3 is the rest of the file - excluding any section headers - // nIndex now points to the first of the 512 '0' characters marking the + // nIndex now points before the first of the 512 '0' characters marking the // fixed content portion - sal_Int32 nLength3 = nFontLen - nIndex; + sal_Int32 nLength3 = nFontLen - nIndex - 1; for( it = aSections.begin(); it != aSections.end(); ++it ) { if( *it >= nIndex ) |
