This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFC V2 [1/2] test-in-container


Andreas Schwab <schwab@linux-m68k.org> writes:
>> +      printf ("unable to open %s for reading\n", sname);
>> +      perror ("the error was");
>
> That doesn't work, the printf call can clobber errno.  Use error instead.

Weird, I've been using that idiom for decades and never had that happen.
But, I'll put it on the list of things to change for V3.

Thanks!


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]