Hello everybody,

I noticed that when I used the PostMethod and a FilePart in order to post a binary file to a server, the file was corrupt when it got to the server. When I compared the file on the server with the original one, I noticed that the file one the server had some bytes more at its beginning than the original one. To resolve this problem, I commented out line 269 in method sendEndOfHeader in Part.java:
protected void sendEndOfHeader(OutputStream out) throws IOException {
     LOG.trace("enter sendEndOfHeader(OutputStream out)");
     out.write(CRLF_BYTES);
     // 21.03.08 had to remove the second carriage return/line feed
     // in order to work correctly with binary files and QNap...
     //out.write(CRLF_BYTES);
}

Because I don't know whether this is really a bug or a user error of mine, I post it in the development mailing list...

Greetings,
Nicolas





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

Reply via email to