Ignore:
Timestamp:
2017-08-11T18:22:36+12:00 (7 years ago)
Author:
ak19
Message:
  1. Previous commit message was incorrect: it wasn't that perl wasn't found that resulted in the open3() failure error message, but that something on the PATH wasn't available to it, possible wget itself. 2. Updating unused DownloadJob.old_callDownload() to have the recently committed changes in callDownload(). 3. Emacs tabbing for recently committed files.
File:
1 edited

Legend:

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

    r31877 r31878  
    111111            // Need to manually specify GSDLHOME and GSDLOS also
    112112           
    113             proxy_url = proxy_url.replaceAll("http://","");
    114            
    115             String [] env = new String[7];
     113            proxy_url = proxy_url.replaceAll("http://","");
    116114           
    117             env[0] = "http_proxy=http://"+proxy_url;
    118             env[1] = "https_proxy=http://"+proxy_url; // yes, HTTP protocol for https:// too
    119                            // see also https://wiki.archlinux.org/index.php/proxy_settings
    120             env[2] = "ftp_proxy=ftp://"+proxy_url;
     115            String [] env = new String[7];
     116           
     117            env[0] = "http_proxy=http://"+proxy_url;
     118            env[1] = "https_proxy=http://"+proxy_url; // yes, HTTP protocol for https:// too
     119            // see also https://wiki.archlinux.org/index.php/proxy_settings
     120            env[2] = "ftp_proxy=ftp://"+proxy_url;
    121121            env[3] = "GSDLHOME=" + Configuration.gsdl_path;
    122122            env[4] = "GSDLOS=" + Gatherer.client_operating_system;
    123             env[5] = "WGETRC=" + LocalGreenstone.getBinOSDirectoryPath(Gatherer.client_operating_system)+"wgetrc"; // teach it where the wgetrc file lives, in gs2build/bin/<os>
    124             // If PATH is not made available, so that Perl is not on the PATH, then WgetDownload.pm's open3() call
    125             // to run wget fails with cryptic failure message. So make PATH available for open3():
    126             env[6] = "PATH="+System.getenv("PATH");
    127            
     123            // teach it where the wgetrc file lives, in gs2build/bin/<os>:
     124            env[5] = "WGETRC=" + LocalGreenstone.getBinOSDirectoryPath(Gatherer.client_operating_system)+"wgetrc";
     125            // Issue discovered on Windows: If PATH is not made available to perl, so that wget or something else needed by
     126            // WgetDownload.pm's open3()  call is not on the PATH, then the perl open() call to run wget fails.
     127            // So make PATH available to get open3() working:
     128            env[6] = "PATH="+System.getenv("PATH");
     129           
    128130            prcs = new SafeProcess(command, env, null);
    129131        }
Note: See TracChangeset for help on using the changeset viewer.