curl-library
Re: sys_nerr warning
From: Daniel Stenberg <daniel-curl_at_haxx.se>
Date: Sun, 4 Apr 2004 22:47:23 +0200 (CEST)
Date: Sun, 4 Apr 2004 22:47:23 +0200 (CEST)
On Sat, 3 Apr 2004, Joe Halpin wrote:
> This patch elminates the warning about sys_nerr on FreeBSD:
> < extern int sys_nerr;
> ---
> > extern const int sys_nerr;
> I'm pretty sure it should be const anyway. This doesn't cause any problems
> on Solaris 9 either.
But my (somewhat oldish) glibc headers have it non-const... :-(
> * The symbols _sys_errlist and _sys_nerr are not visible in the
> * LP64 libc. Use strerror(3C) instead.
I could almost have guessed this. So we need to rewrite the Curl_strerror()
function to avoid using 'sys_nerr' to avoid having to check for it with yet
another configure test. At least for non-Windows platforms.
-- Daniel Stenberg -- http://curl.haxx.se -- http://daniel.haxx.se Dedicated custom curl help for hire: http://haxx.se/curl.htmlReceived on 2004-04-04