[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: getdelim doesn't set errno on failure?
From: |
Oskar Liljeblad |
Subject: |
Re: getdelim doesn't set errno on failure? |
Date: |
Wed, 24 Aug 2005 16:20:17 +0200 |
User-agent: |
Mutt/1.5.10i |
On Wednesday, August 24, 2005 at 15:52, Bruno Haible wrote:
>
> I'm not in favour of a wrapper around malloc(), that would add overhead to
> a function called as frequently as malloc(), just to set 'errno'.
>
> ISO C 99 is not a "substandard", and Windows malloc() is not "poor" just
> because it does not set errno.
>
> What value do you expect in errno after malloc() failed? ENOMEM is
> the most frequent and maybe also the only reasonable choice when malloc()
> fails. What's the purpose then of setting errno then?
>
> ISO C 99 is not a "substandard", and Windows malloc() is not "poor" just
> because it does not set errno.
Gnulib already has a replacement malloc that handles malloc(0). Why not
extend that to set errno on failure as well?
Also, if we are to emulate a standard for broken systems, why not emulate
POSIX?
Regards,
Oskar
- getdelim doesn't set errno on failure?, Oskar Liljeblad, 2005/08/23
- Re: getdelim doesn't set errno on failure?, Jim Meyering, 2005/08/23
- Re: getdelim doesn't set errno on failure?, Oskar Liljeblad, 2005/08/23
- Re: getdelim doesn't set errno on failure?, Bruno Haible, 2005/08/24
- Re: getdelim doesn't set errno on failure?, Jim Meyering, 2005/08/24
- Re: getdelim doesn't set errno on failure?, Bruno Haible, 2005/08/24
- Re: getdelim doesn't set errno on failure?,
Oskar Liljeblad <=
- Re: getdelim doesn't set errno on failure?, Jim Meyering, 2005/08/24
- Re: ISO C 99 versus POSIX 2001, Bruno Haible, 2005/08/24
- Re: ISO C 99 versus POSIX 2001, Paul Eggert, 2005/08/24
- Re: getdelim doesn't set errno on failure?, Oskar Liljeblad, 2005/08/24
- Re: getdelim doesn't set errno on failure?, Derek Price, 2005/08/31
- Re: getdelim doesn't set errno on failure?, Derek Price, 2005/08/31
Re: [bug-gnulib] getdelim doesn't set errno on failure?, Bruno Haible, 2005/08/23