[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: strsignal module
From: |
Colin Watson |
Subject: |
Re: strsignal module |
Date: |
Tue, 15 Jan 2008 00:55:57 +0000 |
User-agent: |
Mutt/1.5.13 (2006-08-11) |
On Tue, Jan 15, 2008 at 12:28:55AM +0100, Bruno Haible wrote:
> You fixed the first portability problem: the function is missing on some
> platforms. But there is another one.
>
> I want to use the replacement in GNU clisp, so I did "man strsignal", and it
> says:
>
> "On some systems (but not on Linux), a NULL pointer may be returned
> instead for an invalid signal number."
>
> And it's even worse than that: for negative or out-of-range signal numbers,
>
> * Solaris strsignal returns NULL,
> * AIX 5.1 strsignal returns (char*)(-1) !
>
> As a user of this function, I don't want to special case these return values.
> The function should always return a reasonable pointer.
Thanks for pointing this out.
> So I propose to change the module so that, on these two platforms, it
> overrides the system function. Do you agree? May I do this? Do you want to
> do it?
I think the attached patch is right (I tested it with LIBS=-lstrsignal
after installing a bogus /usr/lib/libstrsignal.a with a strsignal
function that always returns NULL), but would appreciate review from
those more fluent in Autoconf than I am.
Is it sufficient to test a single value? It's been some time since I had
convenient access to either Solaris or AIX systems.
Cheers,
--
Colin Watson address@hidden
gnulib.strsignal-working.diff
Description: Text Data
- Re: strsignal module, (continued)
Re: strsignal module, Bruno Haible, 2008/01/07
- Re: strsignal module, Colin Watson, 2008/01/08
- Re: strsignal module, Bruno Haible, 2008/01/09
- Re: strsignal module, Colin Watson, 2008/01/13
- Re: strsignal module, Bruno Haible, 2008/01/13
- Re: strsignal module, Bruno Haible, 2008/01/14
- Re: strsignal module, Colin Watson, 2008/01/14
Re: strsignal module, Bruno Haible, 2008/01/14
- Re: strsignal module,
Colin Watson <=