cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: [bagder/curl] e51b23: getpart.pm: Strip carriage returns to fix Windows ...

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Sun, 7 Apr 2013 10:35:53 +0200 (CEST)

On Sun, 7 Apr 2013, Daniel Stenberg wrote:

> Still, curl should write to disk what it gets sent.

More digging and research on this. It kept bugging me.

Okay, the thing is that directories are requested as 'TYPE A' from the ftp
server. 'A' for ASCII, text, as opposed to 'I', binary.

In this case Curl_convert_from_network is called (sendf.c:436) on the data,
and the CRLF line endings can get converted.

I propose that we introduce a new attribute for <data> sections in the test
files for these, so that in addition to what my first patch draft from last
night (that adds the ability to provide the direcory listing in the test
file), marking <data> as text can make runtests.pl do whatever magic is
necessary to have to do pure text comparisons.

We already have such an attribute for the <stdout> section which supports a
mode="text", so reusing that style seems suitable.

BUT

The 7.30.0 release is planned for Wednesday next week, April 10th. I'd rather
not shake the boat too much before then so I suggest we don't merge any
mode="text"-for-<data> changes until after that!

I'll also save my provide-LIST-responses-as-<data> fix until then.

  --

  / daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2013-04-07