PATCH: remove all traces of java.io.FileDescriptor from java.net

Bryce McKinlay bryce@waitaki.otago.ac.nz
Mon Mar 25 09:11:00 GMT 2002


Bryce McKinlay wrote:

> _ZTVN4java3net33PlainSocketImpl$SocketInputStreamE:
>    .long    0
>    .long    0
>    .long    _ZN4java3net33PlainSocketImpl$SocketInputStream6class$E
>    .long    8
>
>
> I'm pretty sure 0x8 is not a valid descriptor! 


Doh! Actually it is just fine - an object where all fields are pointers 
(or where all pointer fields are at the start of the object) is 
represented by the number of fields left shifted by 
log2(bytes-per-pointer). In this case PlainSocketImpl$SocketInputStream 
has two fields, the vtable pointer and this$0.

2 << 2 = 0x8.

regards

Bryce.




More information about the Java-patches mailing list