extensions/source/scanner/sane.cxx |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 6494fba15ea93283b625bf6bdb4666709f22439f
Author:     Caolán McNamara <[email protected]>
AuthorDate: Fri Dec 10 15:34:05 2021 +0000
Commit:     Caolán McNamara <[email protected]>
CommitDate: Fri Dec 10 17:44:42 2021 +0100

    more ofz#42182 oss-build failure
    
    Change-Id: I8960db6c013911df26b35623814c5586ce8c3d00
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126642
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <[email protected]>

diff --git a/extensions/source/scanner/sane.cxx 
b/extensions/source/scanner/sane.cxx
index 20bce0be68d0..de03e1158775 100644
--- a/extensions/source/scanner/sane.cxx
+++ b/extensions/source/scanner/sane.cxx
@@ -169,8 +169,8 @@ Sane::~Sane()
 
 void Sane::Init()
 {
-    OUString sSaneLibName( "libsane" SAL_DLLEXTENSION  );
 #ifndef DISABLE_DYNLOADING
+    OUString sSaneLibName( "libsane" SAL_DLLEXTENSION  );
     pSaneLib = osl_loadModule( sSaneLibName.pData, SAL_LOADMODULE_LAZY );
     if( ! pSaneLib )
     {
@@ -244,7 +244,9 @@ void Sane::DeInit()
     if( pSaneLib )
     {
         p_exit();
+#ifndef DISABLE_DYNLOADING
         osl_unloadModule( pSaneLib );
+#endif
         pSaneLib = nullptr;
     }
 }

Reply via email to