According to Gosling, Microsoft’s decision to support C and C++ in the common language runtime in .NET is one of the "biggest and most offensive mistakes that they could have made" because of these languages' inability to prevent things like arbitrary casting and so on.
Going by this argument, Java should never have had JNI. What prevents a native code call dumping all over your sweet and innocent Java objects?