Re: A patch for comma in filename
Date: Sat, 24 Jun 2006 23:19:22 +0200 (CEST)
On Sun, 25 Jun 2006, Drip Stone wrote:
> I spend some time writing a patch for filenames with comma(s) in it.
> Now to upload a file with commas in filenames, we can use command line:
> curl -F MAX_FILE_SIZE='10485760' -F userfile=@1\,231-102\,307.7z
Thanks for your effort!
I think we should probably start with discussing what the most sensible way is
to fix this problem - with minimizing the risk that existing users run into
problems when they upgrade to the next curl version that includes this fix.
I also think escaping the comma in the file name part isn't a very comfortable
way for users since many will do this in scripts and then this escaping will
be a bit awkward.
As someone else suggested when this was brought up before (I don't remember
who), it could possibly be made with a new option (in the spirit of
--form-string) that accepts nothing but a file upload part and it would then
not accept commas at all as separators.
> If the code is ugly enough, please help me modify it, thanks.
Yes, that was not a nice enough approach.
I'm not interested in a "quick fix". I want it done properly or left as it is
until someone else does it properly!
-- Commercial curl and libcurl Technical Support: http://haxx.se/curl.htmlReceived on 2006-06-24