摘要:
1.报错 Unsafe unsafe = Unsafe.getUnsafe(); java.lang.SecurityException: Unsafe at sun.misc.Unsafe.getUnsafe(Unsafe.java:68) at Person.main(Person.java:37) 这样则正确 Unsafe unsafe =null; try{ Class<?> clazz = Unsafe.class; Field f; f = clazz.getDeclaredField("theUnsafe"); f.setAccessible(tr 阅读全文