DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=31108>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31108

comons-net ftp does not work on zos (ebcdic platform)

           Summary: comons-net ftp does not work on zos (ebcdic platform)
           Product: Commons
           Version: 1.0 Alpha
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Enhancement
          Priority: Other
         Component: Net
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


This was done with 1.3.0-dev  source

The FromNetAscIIInputStream.java constructor

has a string version of   the line separator seq  ("\r\n")

and also a byte array version created with  :
_lineSeparatorBytes =  _lineSeparator.getBytes();
On an ebcdic platform this will result in garbage in the _lineseparatorBytes
and subsequent calls to readLine will timeout because that garbage sequence 
will never be in the "control" inputStream (ASCII by definition)

I bypassed this by  adding encoding of ISO-8859-1 to the initialization of 
_lineSeparatorBytes..
and removing the "final" from the initial declaration

I also swallowed the (almost not possible)  UnsupportedEncodingException.

There is probably a better way to do this as an "official" fix.
Thanks in advance

Stan Long
[EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to