This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH][BZ #12685] Allow arbitrary number of modes in fopen.
- From: "Carlos O'Donell" <carlos at redhat dot com>
- To: "Joseph S. Myers" <joseph at codesourcery dot com>
- Cc: OndÅej BÃlka <neleai at seznam dot cz>, libc-alpha at sourceware dot org
- Date: Thu, 09 May 2013 14:49:22 -0400
- Subject: Re: [PATCH][BZ #12685] Allow arbitrary number of modes in fopen.
- References: <20130509152046 dot GA4242 at domone dot kolej dot mff dot cuni dot cz> <Pine dot LNX dot 4 dot 64 dot 1305091533180 dot 25142 at digraph dot polyomino dot org dot uk>
On 05/09/2013 11:34 AM, Joseph S. Myers wrote:
> On Thu, 9 May 2013, Ondrej Bilka wrote:
>
>> Hi,
>>
>> I implemented Michael Kerrisk's suggestion from
>> http://sourceware.org/bugzilla/show_bug.cgi?id=12685
>> to read mode until NULL or comma (for ,ccs=) is reached.
>>
>> OK to commit?
>>
>> Ondra
>>
>> * libio/fileops.c (_IO_new_file_fopen): Allow arbitrary number of modes.
>> * libio/iofdopen.c (_IO_new_fdopen): Likewise.
>
> I think this should add testcases (for both functions) that a mode late in
> a long string is properly handled.
>
I agree we need test cases for this to prevent regression.
Cheers,
Carlos.