You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ftpserver-dev@incubator.apache.org by Niklas Gustavsson <ni...@protocol7.com> on 2007/05/05 17:05:22 UTC

Re: Question regarding upload of files that use CR+LF as line terminators

Clinton Foster wrote:
 > Anyway, something isn't right because I remember seeing problems with the
 > line enders using a client that was known to behave correctly.

If you're able to isolate the problem, please open a JIRA issue and I'll 
have a look at it.

/niklas


Re: Question regarding upload of files that use CR+LF as line terminators

Posted by Peter Kostouros <kp...@melbpc.org.au>.
Niklas Gustavsson wrote:
> Peter Kostouros wrote:
>> How about ../trunk/core/src/test/org/apache/ftpserver/StoreTest.java 
>> as a starting point:
>
>> +    private static final String TESTDATA = "TESTDATA\r\nline2\r\n";
>
> Excellent test case :-)
>
> Now, in this case, when a file already contains \r\n line endings, 
> we'll would be sending them as \r\r\n. Just like you pointed out Peter.
>
> I've created an issue over at 
> https://issues.apache.org/jira/browse/FTPSERVER-84 and committed the 
> fix in rev 535977. Please verify that this fixes your issue and thanks 
> for reporting it!
>
Looks OK to me. Thanks!

> /niklas
>
>


-- 

Regards

Peter

As always the organisation disavows knowledge of this email


Re: Question regarding upload of files that use CR+LF as line terminators

Posted by Niklas Gustavsson <ni...@protocol7.com>.
Peter Kostouros wrote:
> How about ../trunk/core/src/test/org/apache/ftpserver/StoreTest.java as 
> a starting point:

> +    private static final String TESTDATA = "TESTDATA\r\nline2\r\n";

Excellent test case :-)

Now, in this case, when a file already contains \r\n line endings, we'll 
would be sending them as \r\r\n. Just like you pointed out Peter.

I've created an issue over at 
https://issues.apache.org/jira/browse/FTPSERVER-84 and committed the fix 
in rev 535977. Please verify that this fixes your issue and thanks for 
reporting it!

/niklas


Re: Question regarding upload of files that use CR+LF as line terminators

Posted by Peter Kostouros <kp...@melbpc.org.au>.
Hi

Niklas Gustavsson wrote:
> Clinton Foster wrote:
> > Anyway, something isn't right because I remember seeing problems 
> with the
> > line enders using a client that was known to behave correctly.
>
> If you're able to isolate the problem, please open a JIRA issue and 
> I'll have a look at it.
>

How about ../trunk/core/src/test/org/apache/ftpserver/StoreTest.java as 
a starting point:

--- StoreTest.java~    Mon Mar 12 09:10:51 2007
+++ StoreTest.java    Sat May  5 18:17:09 2007
@@ -27,7 +27,7 @@
 
 
 public class StoreTest extends ClientTestTemplate {
-    private static final String TESTDATA = "TESTDATA";
+    private static final String TESTDATA = "TESTDATA\r\nline2\r\n";
 
     private static final String ENCODING = "UTF-8";
 
> /niklas
>
>


-- 

Regards

Peter

As always the organisation disavows knowledge of this email