Changeset 21998

Show
Ignore:
Timestamp:
29.04.2010 16:40:17 (9 years ago)
Author:
ak19
Message:

Fix to recent commit: embedding path to server script in quotes broke on Linux. So now we do this only for Windows.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/gli/src/org/greenstone/gatherer/greenstone/LocalLibraryServer.java

    r21965 r21998  
    231231 
    232232    // Spawn local library server process 
    233     String local_library_server_command = "\""+local_library_server_file.getAbsolutePath()+"\"" + getExtraLaunchArguments(llssite_cfg_file); 
     233    final String QUOTES = Utility.isWindows() ? "\"" : ""; // need to embed path in quotes on Windows for spaces (interferes on Linux) 
     234    String local_library_server_command = QUOTES+local_library_server_file.getAbsolutePath()+QUOTES + getExtraLaunchArguments(llssite_cfg_file); 
    234235    if(Utility.isWindows() && !isPersistentServer) { // launching gs2-server.bat (Windows) needs cmd start 
    235236        local_library_server_command = "cmd.exe /c start \"GSI\" " + local_library_server_command; 
     
    487488        // Spawn local library server process 
    488489        running = false; 
    489         String local_library_server_command = "\""+local_library_server_file.getAbsolutePath()+"\"" + getExtraLaunchArguments(llssite_cfg_file); 
     490        final String QUOTES = Utility.isWindows() ? "\"" : ""; // need to embed path in quotes on Windows for spaces (interferes on Linux) 
     491        String local_library_server_command = QUOTES+local_library_server_file.getAbsolutePath()+QUOTES + getExtraLaunchArguments(llssite_cfg_file); 
    490492        if(Utility.isWindows() && !isPersistentServer) { // launching gs2-server.bat (Windows) needs cmd start 
    491493            local_library_server_command = "cmd.exe /c start \"GSI\" " + local_library_server_command;