filter/source/graphicfilter/icgm/bundles.cxx | 5 +---- filter/source/graphicfilter/icgm/bundles.hxx | 3 +-- filter/source/graphicfilter/icgm/cgmtypes.hxx | 1 - filter/source/graphicfilter/icgm/class1.cxx | 4 ++-- 4 files changed, 4 insertions(+), 9 deletions(-)
New commits: commit 8a14fb988e718cf08e1545d81683fbc95ad24e12 Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Mon Dec 16 09:03:08 2019 +0000 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Mon Dec 16 12:21:49 2019 +0100 ofz#19525 Invalid enum value value is unused anyway, so just reflect that Change-Id: I032f477dddd4d50c791898eb214dac2dbbb69f09 Reviewed-on: https://gerrit.libreoffice.org/85203 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caol...@redhat.com> Tested-by: Caolán McNamara <caol...@redhat.com> diff --git a/filter/source/graphicfilter/icgm/bundles.cxx b/filter/source/graphicfilter/icgm/bundles.cxx index 6754b9bccaf2..2bb36999de98 100644 --- a/filter/source/graphicfilter/icgm/bundles.cxx +++ b/filter/source/graphicfilter/icgm/bundles.cxx @@ -29,7 +29,6 @@ void Bundle::SetColor( sal_uInt32 nColor ) } FontEntry::FontEntry() : - eCharSetType ( CST_CCOMPLETE ), nFontType ( 0 ) { } @@ -74,7 +73,6 @@ CGMFList& CGMFList::operator=( const CGMFList& rSource ) pCFontEntry->pCharSetValue.reset( new sal_Int8[ nSize ] ); memcpy( pCFontEntry->pCharSetValue.get(), pPtr->pCharSetValue.get(), nSize ); } - pCFontEntry->eCharSetType = pPtr->eCharSetType; pCFontEntry->nFontType = pPtr->nFontType; aFontEntryList.push_back( std::move(pCFontEntry) ); } @@ -169,7 +167,7 @@ void CGMFList::InsertName( sal_uInt8 const * pSource, sal_uInt32 nSize ) } -void CGMFList::InsertCharSet( CharSetType eCharSetType, sal_uInt8 const * pSource, sal_uInt32 nSize ) +void CGMFList::InsertCharSet( sal_uInt8 const * pSource, sal_uInt32 nSize ) { FontEntry* pFontEntry; if ( nFontsAvailable == nCharSetCount ) @@ -183,7 +181,6 @@ void CGMFList::InsertCharSet( CharSetType eCharSetType, sal_uInt8 const * pSourc pFontEntry = aFontEntryList[ nCharSetCount ].get(); } nCharSetCount++; - pFontEntry->eCharSetType = eCharSetType; pFontEntry->pCharSetValue.reset( new sal_Int8[ nSize + 1 ] ); pFontEntry->pCharSetValue[ nSize ] = 0; memcpy( pFontEntry->pCharSetValue.get(), pSource, nSize ); diff --git a/filter/source/graphicfilter/icgm/bundles.hxx b/filter/source/graphicfilter/icgm/bundles.hxx index 1f9bf7bb29df..8d87bac2082b 100644 --- a/filter/source/graphicfilter/icgm/bundles.hxx +++ b/filter/source/graphicfilter/icgm/bundles.hxx @@ -143,7 +143,6 @@ class FontEntry public: std::unique_ptr<sal_Int8[]> pFontName; - CharSetType eCharSetType; std::unique_ptr<sal_Int8[]> pCharSetValue; sal_uInt32 nFontType; // bit 0 = 1 -> Italic, @@ -169,7 +168,7 @@ public: FontEntry* GetFontEntry( sal_uInt32 ); void InsertName( sal_uInt8 const * pSource, sal_uInt32 nSize ); - void InsertCharSet( CharSetType, sal_uInt8 const * pSource, sal_uInt32 nSize ); + void InsertCharSet( sal_uInt8 const * pSource, sal_uInt32 nSize ); CGMFList& operator=( const CGMFList& rFontList ); }; diff --git a/filter/source/graphicfilter/icgm/cgmtypes.hxx b/filter/source/graphicfilter/icgm/cgmtypes.hxx index a245ebcbf3b2..b9a80fb4c83a 100644 --- a/filter/source/graphicfilter/icgm/cgmtypes.hxx +++ b/filter/source/graphicfilter/icgm/cgmtypes.hxx @@ -97,7 +97,6 @@ enum ColorSelectionMode { CSM_INDEXED = 0, CSM_DIRECT = 1 }; enum ColorModel { CM_RGB = 0, CM_CMYK = 1 }; enum CharacterCodingA { CCA_BASIC_7 = 0, CCA_BASIC_8 = 1, CCA_EXT_7 = 2, CCA_EXT_8 = 3 }; -enum CharSetType { CST_CBYTE_94 = 0, CST_CBYTE_96 = 1, CST_MULT94 = 2, CST_MULT96 = 3, CST_CCOMPLETE = 4 }; enum TextPrecision { TPR_STRING = 0, TPR_CHARACTER = 1, TPR_STROKE = 2, TPR_UNDEFINED = 0xffff }; enum TextPath { TPR_RIGHT = 0, TPR_LEFT = 1, TPR_UP = 2, TPR_DOWN = 3 }; enum TextAlignmentH { TAH_NORMAL = 0, TAH_LEFT = 1, TAH_CENTER = 2, TAH_RIGHT = 3, TAH_CONT = 4 }; diff --git a/filter/source/graphicfilter/icgm/class1.cxx b/filter/source/graphicfilter/icgm/class1.cxx index 22a65bf11f05..0adee25234f9 100644 --- a/filter/source/graphicfilter/icgm/class1.cxx +++ b/filter/source/graphicfilter/icgm/class1.cxx @@ -180,13 +180,13 @@ void CGM::ImplDoClass1() { while ( mnParaSize < mnElementSize ) { - sal_uInt32 nCharSetType = ImplGetUI16(); + ImplGetUI16(); // skip CharSetType sal_uInt32 nSize = ImplGetUI(1); if (static_cast<sal_uIntPtr>(mpEndValidSource - (mpSource + mnParaSize)) < nSize) throw css::uno::Exception("attempt to read past end of input", nullptr); - pElement->aFontList.InsertCharSet( static_cast<CharSetType>(nCharSetType), mpSource + mnParaSize, nSize ); + pElement->aFontList.InsertCharSet( mpSource + mnParaSize, nSize ); mnParaSize += nSize; } } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits