[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.0' - vcl/source

Tor Lillqvist (via logerrit) logerrit at kemper.freedesktop.org
Tue Jun 4 11:39:15 UTC 2019


 vcl/source/filter/graphicfilter.cxx |   30 ++++++++++++++----------------
 1 file changed, 14 insertions(+), 16 deletions(-)

New commits:
commit b60ac2d6fc46aa5e44c1c9375aa37825ee07683f
Author:     Tor Lillqvist <tml at collabora.com>
AuthorDate: Tue Jun 4 14:20:45 2019 +0300
Commit:     Tor Lillqvist <tml at collabora.com>
CommitDate: Tue Jun 4 14:37:33 2019 +0300

    Fix "external" graphic filter code for the DISABLE_DYNLOADING case
    
    The DISABLE_DYNLOADING case in ImpFilterLibCacheEntry::GetImportFunction()
    had apparently been broken from the start, but nobody never noticed as
    the common formats (PNG, JPEG, GIF etc) use a more "internal"code
    path. The problem was noticed now with a TIFF image in a presentation.
    
    The fix for the import case seems to work, but I could not test the
    fix for the export case.
    
    Change-Id: Icbd33c7cb654136a562f18b06d5b0896e701bf3d

diff --git a/vcl/source/filter/graphicfilter.cxx b/vcl/source/filter/graphicfilter.cxx
index 7a869a7aee4b..bef80fb94b24 100644
--- a/vcl/source/filter/graphicfilter.cxx
+++ b/vcl/source/filter/graphicfilter.cxx
@@ -976,27 +976,27 @@ PFilterCall ImpFilterLibCacheEntry::GetImportFunction()
         else if (maFormatName == "iti")
             mpfnImport = reinterpret_cast<PFilterCall>(maLibrary.getFunctionSymbol("itiGraphicImport"));
  #else
-        if (maFiltername ==  "icd")
+        if (maFormatName ==  "icd")
             mpfnImport = icdGraphicImport;
-        else if (maFiltername ==  "idx")
+        else if (maFormatName ==  "idx")
             mpfnImport = idxGraphicImport;
-        else if (maFiltername ==  "ime")
+        else if (maFormatName ==  "ime")
             mpfnImport = imeGraphicImport;
-        else if (maFiltername ==  "ipb")
+        else if (maFormatName ==  "ipb")
             mpfnImport = ipbGraphicImport;
-        else if (maFiltername ==  "ipd")
+        else if (maFormatName ==  "ipd")
             mpfnImport = ipdGraphicImport;
-        else if (maFiltername ==  "ips")
+        else if (maFormatName ==  "ips")
             mpfnImport = ipsGraphicImport;
-        else if (maFiltername ==  "ipt")
+        else if (maFormatName ==  "ipt")
             mpfnImport = iptGraphicImport;
-        else if (maFiltername ==  "ipx")
+        else if (maFormatName ==  "ipx")
             mpfnImport = ipxGraphicImport;
-        else if (maFiltername ==  "ira")
+        else if (maFormatName ==  "ira")
             mpfnImport = iraGraphicImport;
-        else if (maFiltername ==  "itg")
+        else if (maFormatName ==  "itg")
             mpfnImport = itgGraphicImport;
-        else if (maFiltername ==  "iti")
+        else if (maFormatName ==  "iti")
             mpfnImport = itiGraphicImport;
  #endif
     }
@@ -1925,9 +1925,7 @@ ErrCode GraphicFilter::ExportGraphic( const Graphic& rGraphic, const OUString& r
 
     FilterConfigItem aConfigItem( pFilterData );
     OUString aFilterName( pConfig->GetExportFilterName( nFormat ) );
-#ifndef DISABLE_DYNLOADING
     OUString aExternalFilterName(pConfig->GetExternalFilterName(nFormat, true));
-#endif
     ErrCode     nStatus = ERRCODE_NONE;
     GraphicType eType;
     Graphic     aGraphic( rGraphic );
@@ -2226,11 +2224,11 @@ ErrCode GraphicFilter::ExportGraphic( const Graphic& rGraphic, const OUString& r
                  // Execute dialog in DLL
  #else
                 PFilterCall pFunc = NULL;
-                if (aFilterName == "egi")
+                if (aExternalFilterName == "egi")
                     pFunc = egiGraphicExport;
-                else if (aFilterName == "eps")
+                else if (aExternalFilterName == "eps")
                     pFunc = epsGraphicExport;
-                else if (aFilterName == "eti")
+                else if (aExternalFilterName == "eti")
                     pFunc = etiGraphicExport;
  #endif
                 if( pFunc )


More information about the Libreoffice-commits mailing list