Bug 6064 - GridFTP file listing on from windows client fails
: GridFTP file listing on from windows client fails
Status: RESOLVED FIXED
: CoG jglobus
ftp
: 1.4
: PC Windows XP
: P3 blocker
: 1.6
Assigned To:
:
:
:
:
  Show dependency treegraph
 
Reported: 2008-05-06 21:00 by
Modified: 2008-09-29 18:01 (History)


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2008-05-06 21:00:30
In org.globus.ftp.FTPClient.list(String filter, String modifier) lines 441/442
need to be replaced with: 

BufferedReader reader = new BufferedReader(new
StringReader(sink.getData().toString().replaceAll("\r", "")));

As (atleast for me) the string tokenizer in Java 6 on windows splits the reply
string from the server incorrectly because of the \r characters.
------- Comment #1 From 2008-08-07 16:01:30 -------
Instead of subing out the \r i want to go with this approach:

+
         while ((line = reader.readLine()) != null) {
+            line = line.trim();
             if (logger.isDebugEnabled()) {
                 logger.debug("line ->" + line);
             }
+            if(line.equals(""))
+            {
+                continue;
+            }

basically trim out the white space and skip the line if it is empty.  I do not
have a windows test bed, would you be willing to give this a try for me and
verify it solves your problem?