Changeset 20957

Show
Ignore:
Timestamp:
18.11.2009 15:51:36 (10 years ago)
Author:
ak19
Message:

When dealing with a remote Greenstone server, file separators need to be replaced with vertical bar since we don't know what operating system the remote GS server is (and hence what File separator it uses).

Location:
gli/trunk/src/org/greenstone/gatherer/gui
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • gli/trunk/src/org/greenstone/gatherer/gui/ExplodeMetadataDatabasePrompt.java

    r20924 r20957  
    289289        String metadata_file_relative_path = Gatherer.remoteGreenstoneServer.getPathRelativeToDirectory( 
    290290                                                          metadata_file, collection_directory_path); 
     291        metadata_file_relative_path = metadata_file_relative_path.replace(File.separatorChar, '|'); 
    291292        command_parts_list.add("-file"); 
    292293        command_parts_list.add(Base64.encodeBytes(metadata_file_relative_path.getBytes())); 
  • gli/trunk/src/org/greenstone/gatherer/gui/ReplaceSrcDocWithHtmlPrompt.java

    r20924 r20957  
    284284        String srcdoc_file_relative_path = Gatherer.remoteGreenstoneServer.getPathRelativeToDirectory( 
    285285        this.srcdoc_files[fileNum], collection_directory_path); // preserves spaces in filename 
     286        srcdoc_file_relative_path = srcdoc_file_relative_path.replace(File.separatorChar, '|'); 
    286287 
    287288        // base64 encode the relative filepath, so that special characters in the filename are preserved