pyuno/source/module/uno.py |    2 ++
 1 file changed, 2 insertions(+)

New commits:
commit cd048ca7ab61718586f7ef5b48dccbb6bd38299c
Author:     Niko Fink <[email protected]>
AuthorDate: Tue Aug 9 09:17:00 2022 +0200
Commit:     Thorsten Behrens <[email protected]>
CommitDate: Tue Aug 9 15:35:22 2022 +0200

    tdf#133123: fix crash when importing defusedxml.ElementTree after pyuno
    
    Change-Id: I89ac6108c679504c81dd9a439a4fb02e9e1adc07
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138007
    Tested-by: Jenkins
    Reviewed-by: Michael Stahl <[email protected]>
    (cherry picked from commit 1052ec9cff72e2810fdb934a85ab500d3b4ace35)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138018
    Reviewed-by: Thorsten Behrens <[email protected]>

diff --git a/pyuno/source/module/uno.py b/pyuno/source/module/uno.py
index 5fa7b135736d..b2a75bd03982 100644
--- a/pyuno/source/module/uno.py
+++ b/pyuno/source/module/uno.py
@@ -365,6 +365,8 @@ def _uno_import(name, *optargs, **kwargs):
         else:
             # How to create a module ??
             mod = pyuno.__class__(module)
+        if mod is None:
+            raise py_import_exc
 
         d = mod.__dict__
 

Reply via email to