[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [screen-devel] RE: [PATCH] Fixing configure script and removing LOTS
Re: [screen-devel] RE: [PATCH] Fixing configure script and removing LOTS of GCC warnings on HP-UX
Wed, 12 Nov 2008 08:53:46 -0800
Thunderbird 184.108.40.206 (X11/20080925)
-----BEGIN PGP SIGNED MESSAGE-----
Gavrichenkov, Artyom wrote:
>> But this defines strlen to return the wrong type! (At least, the HP-UX
>> machine I have handy has strlen returning int.)
> On several HP-UX machines near me the following is true:
>> printf '%s %s %s\n' `uname -s` `uname -r` `uname -m`
> HP-UX B.11.23 ia64
>> grep strlen /usr/include/string.h | grep -v ^#\ \*pragma
> extern int strlen();
> extern size_t strlen(char *);
> extern size_t strlen(const char *);
> extern size_t strlen();
> where the first declaration is under #ifdef _CLASSIC_ANSI_TYPES -- this macro
> isn't used anywhere in Screen code, isn't it?
> I may provide you our string.h if it's needed, but you may look in
> documentation as well: http://docs.hp.com/en/B2355-60127/index.html
> Anyway, even in case some (old?) HP-UX versions had strlen() returning int
> (guess it converted to size_t), it's better to have a declaration with size_t
> than no declaration at all.
> I've attached new patch. You may ignore it if you choose so (that's just
> warnings after all).
Thanks for the summary!
Actually, after I saw Juergen's conclusion that it was just old cruft, I
added checks to the configure script for string.h and strings.h, and
just plopped those headers in, expecting they should DTRT.
Micah J. Cowan
Programmer, musician, typesetting enthusiast, gamer.
GNU Maintainer: wget, screen, teseq
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----