[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - setup_native/scripts

Christian Lohmaier lohmaier+LibreOffice at googlemail.com
Thu Jul 25 23:52:34 PDT 2013


 setup_native/scripts/osx_install_languagepack.applescript |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

New commits:
commit 80328f390eceb32e1530ca182e6b135c3a0b0264
Author: Christian Lohmaier <lohmaier+LibreOffice at googlemail.com>
Date:   Wed Jul 24 16:28:04 2013 +0200

    fdo#67258 catch error when calling mdfind
    
    This can be the case when spotlight is disabled. So just ignore any
    error when trying to locate installed versions and let the user continue
    with the manual selection instead of aborting.
    
    Change-Id: I2c4e12652b8cb3b43af3ca6d8d553f0558f91858
    Reviewed-on: https://gerrit.libreoffice.org/5069
    Reviewed-by: Fridrich Strba <fridrich at documentfoundation.org>
    Tested-by: Fridrich Strba <fridrich at documentfoundation.org>
    Reviewed-on: https://gerrit.libreoffice.org/5118

diff --git a/setup_native/scripts/osx_install_languagepack.applescript b/setup_native/scripts/osx_install_languagepack.applescript
index 3b16499..735f141 100644
--- a/setup_native/scripts/osx_install_languagepack.applescript
+++ b/setup_native/scripts/osx_install_languagepack.applescript
@@ -63,7 +63,12 @@ if (button returned of result) is AbortLabel then
 	return 2
 end if
 
-set the found_ooos_all to (do shell script "mdfind \"kMDItemContentType == 'com.apple.application-bundle' && kMDItemDisplayName == '[PRODUCTNAME]*' && kMDItemDisplayName != '[FULLAPPPRODUCTNAME].app'\"") & "
+set found_ooos_all to ""
+-- command might return an error if spotlight is disabled completely
+try
+	set found_ooos_all to (do shell script "mdfind \"kMDItemContentType == 'com.apple.application-bundle' && kMDItemDisplayName == '[PRODUCTNAME]*' && kMDItemDisplayName != '[FULLAPPPRODUCTNAME].app'\"")
+end try
+set found_ooos_all to found_ooos_all & "
 " & chooseMyOwn
 
 set found_ooos_all_paragraphs to paragraphs in found_ooos_all


More information about the Libreoffice-commits mailing list