Date: Mon, 5 Nov 2001 14:54:15 -0500 (EST) From: Garrett Wollman <wollman@khavrinen.lcs.mit.edu> To: Hajimu UMEMOTO <ume@mahoroba.org> Cc: current@FreeBSD.ORG Subject: Re: About stscasestr() prototyped with string.h of current lib Message-ID: <200111051954.fA5JsFf90126@khavrinen.lcs.mit.edu> In-Reply-To: <20011102.220113.74678450.ume@mahoroba.org> References: <20011102.173604.78790653.nin@smtp.shikoku.ne.jp> <20011102120117.A87038@nagual.pp.ru> <20011102.220113.74678450.ume@mahoroba.org>
next in thread | previous in thread | raw e-mail | index | archive | help
<<On Fri, 02 Nov 2001 22:01:13 +0900 (JST), Hajimu UMEMOTO <ume@mahoroba.org> said: > I think nin said that having strcasestr() in our standard header > breaks existing program. Those programs are wrong, since strcasestr() is in the Implementation Namespace. The correct code (assuming one is using autoconf-like feature testing) would look something like: #ifdef HAVE_STRCASESTR /* assume <string.h> already included */ #define my_strcasestr(a, b) strcasestr((a), (b)) #else const char *my_strcasestr(const char *, const char *); #endif -GAWollman To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200111051954.fA5JsFf90126>