bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 32-bit glibc bug with SSIZE_MAX


From: Eric Blake
Subject: Re: 32-bit glibc bug with SSIZE_MAX
Date: Wed, 13 Jul 2016 07:38:14 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0

On 07/13/2016 06:12 AM, Eric Blake wrote:

>> +The macro @code{SSIZE_MAX} has the wrong type,
>> +albeit with the correct value:
>> +glibc 2.24.
>> address@hidden
> 
> Only 32-bit glibc is buggy; 64-bit glibc is okay.

Worse, it's platform-dependent. On 32-bit s390, SSIZE_MAX is the correct
type, but SIZE_MAX is broken (unsigned int, even though size_t is
unsigned long).

> 
> I suppose we should do a similar patch for 64-bit OSX, which has
> <stdint.h> declaring SIZE_MAX with the wrong type (unsigned long long,
> while size_t is merely unsigned long).  But at least there, we already
> have a replacement stdint.h.
> 

I'll push a followup doc patch later today to cover the additional
corner cases.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]