This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc 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]

[Bug libc/19995] Linux syscall return value unnecessarily relies on implementation-defined behaviour


https://sourceware.org/bugzilla/show_bug.cgi?id=19995

--- Comment #1 from joseph at codesourcery dot com <joseph at codesourcery dot com> ---
On Tue, 26 Apr 2016, mt at debian dot org wrote:

> The unsigned -> signed conversion is implementation-defined for any values that
> cannot be represented in the signed type (as will be the case with any negative
> return value if it's two's complement). This seems to be case where relying on
> implementation-defined behaviour could be avoided.

This is fully defined in GNU C, and as far as I know in the consensus 
between all normal C implementations in current use (although it's not one 
of the areas covered in the Cerberus survey).  I see no reason whatever to 
avoid it anywhere in glibc.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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