[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: read-file
From: |
Simon Josefsson |
Subject: |
Re: read-file |
Date: |
Fri, 16 Jun 2006 21:45:10 +0200 |
User-agent: |
Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (gnu/linux) |
address@hidden (Larry Jones) writes:
> Aaron Stone writes:
>>
>> If I were using a function like this, I'd expect NULL on error (and
>> errno set according to fopen), and an empty string if the file is empty.
>
> Note that the C Standard doesn't require fopen to set errno and
> traditional implementations didn't, at least in some cases.
The docstring intentionally avoids saying that errno is set to
something useful:
*LENGTH. On errors, *LENGTH is undefined, errno preserves the
values set by system functions (if any), and NULL is returned. */
I guess it could explicitly set errno, but I'm not sure that is such a
good style either...
- read-file (was: strfile), Simon Josefsson, 2006/06/16
- Re: [bug-gnulib] read-file (was: strfile), Bruno Haible, 2006/06/16
- Re: read-file, Paul Eggert, 2006/06/16
- Re: read-file, Aaron Stone, 2006/06/16
- Re: read-file, Larry Jones, 2006/06/16
- Re: read-file,
Simon Josefsson <=
- Re: read-file, Simon Josefsson, 2006/06/16
- Re: read-file, Larry Jones, 2006/06/16
- Re: read-file, Simon Josefsson, 2006/06/16
- Re: read-file, Larry Jones, 2006/06/16
- Re: read-file, Paul Eggert, 2006/06/19
Re: read-file, Simon Josefsson, 2006/06/16