lkml.org 
[lkml]   [1999]   [Aug]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] 2.3.14: bug-fix for raw IO error recovery
> Don't do this. It leads to all kinds of problems for 64-bit architectures,
> I'm not at all sure that casting (int) -1 to a pointer is at all safe. I
> would not be surprised if it is entirely legal and expected on some
> architectures for it to become 0x00000000ffffffff, which might be a
> perfectly valid pointer.

what about something like:

blah = (void*) (~0uL)

sort of thing? (Assuming sizeof(long) == sizeof(void*))




-cw

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:53    [W:1.211 / U:0.144 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site