[openssl-dev] [openssl.org #4443] Re: VIA C7-D processor: Hang in 30-test_afalg.t

Jeffrey Walton noloader at gmail.com
Fri Mar 18 07:50:37 UTC 2016


>> This is bad news... A 32-bit pointer's sign extension is
>> implementation defined, which means it may as well be undefined
>> behavior...
>>
>> GCC sign extends. I think you can get around it with an intermediate
>> cast to uintptr_t:
>>
>>    cb->aio_buf = (uint64_t)(uintptr_t)buf;
>
> The kernel sources seem to use a cast to (unsigned long) in the system
> call definitions...  Someone else will have to figure out how this is
> supposed to work...

Yeah, maybe Andy can jump in.

I known what the kernel is doing is just plain wrong because the C
language does not make the size guarantees they are depending on. For
some reason, they feel the C language rules don't apply to them. The
language rules are important because that's what the compiler authors
follow. Q.v...


More information about the openssl-dev mailing list