RFR: 8001579, security code modifications that eliminate compiler warnings, etc.

John Zavgren john.zavgren at oracle.com
Mon Oct 29 06:06:24 PDT 2012


Greetings:

I modified several files in the core library security code:

src/share/native/sun/security/jgss/wrapper/GSSLibStub.c
src/share/native/sun/security/jgss/wrapper/NativeUtil.c
src/share/native/sun/security/pkcs11/wrapper/p11_convert.c
src/share/native/sun/security/pkcs11/wrapper/p11_crypt.c
src/share/native/sun/security/pkcs11/wrapper/p11_digest.c
src/share/native/sun/security/pkcs11/wrapper/p11_general.c
src/share/native/sun/security/pkcs11/wrapper/p11_sessmgmt.c
src/share/native/sun/security/pkcs11/wrapper/p11_sign.c
src/share/native/sun/security/pkcs11/wrapper/p11_util.c
src/solaris/native/sun/security/pkcs11/j2secmod_md.c
src/solaris/native/sun/security/pkcs11/wrapper/p11_md.c

to eliminate compiler warnings. I used the OS-independent ptr_to_jlong() and jlong_to_ptr() macros to ensure that casting is done correctly, changed local variables to have the correct type before comparison (unsigned versus signed integers), made format strings and arguments consistent, initialized one data structure (memory was being accessed before initialization), initialized several local variables, etc.

The webrev image of these changes is located at: http://cr.openjdk.java.net/~alanb/8001579/webrev/

I look forward to your comments.

Thanks!
John Zavgren



More information about the security-dev mailing list