Well if we're being pedantic and imprecise to boot ... > >> malloc() returns a char*, not a jbyte*.
malloc() returns void* not char*. It hasn't returned char* since pre ANSI C. Hence the pointer returned by malloc can be legally converted to any real pointer type with clearly defined semantics. Taking the address of a void* and pretending that it is the address of a jbyte* is not legal. However, it is legal to convert between an int and a pointer type and a pointer type and an int. If the address represented by the int is incorrectly aligned for the pointer type then the result is undefined. Otherwise the result is implementation specific. Hence you can write legal but (by definition) non-portable code to do what you want. David Holmes _______________________________________________ Classpath mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/classpath