This is the mail archive of the newlib@sourceware.org mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: fix <ctype.h> bugs on 64-bit machine


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Eric Blake on 10/19/2009 2:21 PM:
> Bruno Haible pointed out to me that on 64-bit machines, the use of isalpha
> (0x100000001LL) will cause an out-of-bounds array dereference, rather than 
> returning the correct result of isalpha(1).

Ping.

> 2009-10-19  Eric Blake  <ebb9@byu.net>
> 
> 	* libc/include/ctype.h (__ctype_lookup): New macro.
> 	(isalpha, isupper, islower, isdigit, isxdigit, isspace, ispunct)
> 	(isalnum, isprint, isgraph, iscntrl, isblank): Use it to fix bug
> 	on 64-bit machines.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             ebb9@byu.net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkrhmI8ACgkQ84KuGfSFAYCqIQCfSyILZv46HL8Gj//vvXgjRhU/
AdUAn2H+djL1JO6gcVBi1ON04y+XSSt7
=3hVr
-----END PGP SIGNATURE-----


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]