[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - shell/source

Stephan Bergmann (via logerrit) logerrit at kemper.freedesktop.org
Wed Nov 25 13:05:39 UTC 2020


 shell/source/unix/exec/shellexec.cxx |    4 ++++
 shell/source/win32/SysShExec.cxx     |    3 ++-
 2 files changed, 6 insertions(+), 1 deletion(-)

New commits:
commit ec5adc39cbea6d754ef68ab3d03fb16066b27e40
Author:     Stephan Bergmann <sbergman at redhat.com>
AuthorDate: Wed Nov 25 09:13:12 2020 +0100
Commit:     Stephan Bergmann <sbergman at redhat.com>
CommitDate: Wed Nov 25 14:04:57 2020 +0100

    Better handling of Java files
    
    Change-Id: Ifa662be39ac7d35241ee31956e2556b7ba3b5a02
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106558
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>
    (cherry picked from commit 696739056f37430154d6333b8f7228d1c44d09b3)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106520
    Reviewed-by: Michael Stahl <michael.stahl at cib.de>

diff --git a/shell/source/unix/exec/shellexec.cxx b/shell/source/unix/exec/shellexec.cxx
index 58c5ef4661d8..3ac5fad2e0af 100644
--- a/shell/source/unix/exec/shellexec.cxx
+++ b/shell/source/unix/exec/shellexec.cxx
@@ -150,6 +150,10 @@ void SAL_CALL ShellExec::execute( const OUString& aCommand, const OUString& aPar
             {
                 throw css::lang::IllegalArgumentException(
                     "XSystemShellExecute.execute, cannot process <" + aCommand + ">", {}, 0);
+            } else if (pathname.endsWithIgnoreAsciiCase(".class")
+                       || pathname.endsWithIgnoreAsciiCase(".jar"))
+            {
+                dir = true;
             }
         }
 
diff --git a/shell/source/win32/SysShExec.cxx b/shell/source/win32/SysShExec.cxx
index 93eeaee36f03..c98940be64a1 100644
--- a/shell/source/win32/SysShExec.cxx
+++ b/shell/source/win32/SysShExec.cxx
@@ -331,7 +331,8 @@ void SAL_CALL CSysShExec::execute( const OUString& aCommand, const OUString& aPa
                 }
                 if (!(checkExtension(ext, env)
                       && checkExtension(
-                          ext, ".COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.PY")))
+                          ext,
+                          ".COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.PY;.CLASS;.JAR")))
                 {
                     throw css::lang::IllegalArgumentException(
                         "XSystemShellExecute.execute, cannot process <" + aCommand + ">", {}, 0);


More information about the Libreoffice-commits mailing list