Commits


Laurent Goujon authored and GitHub committed 6bba2036a5b
GH-43479: [Java] Change visibility of MemoryUtil.UNSAFE (#43480) ### Rationale for this change `MemoryUtil.UNSAFE` field is a public field which provides unrestricted access to `sun.misc.Unsafe` instance which may cause misusage and possibly JVM crashes. ### What changes are included in this PR? Make the field (and other related fields) private and only allow indirect use of Unsafe through `MemoryUtil` methods ### Are these changes tested? Yes. ### Are there any user-facing changes? No **This PR includes breaking changes to public APIs.** Code using `MemoryUtil.UNSAFE` would break as the visibility of the field was changed to private * GitHub Issue: #43479 Authored-by: Laurent Goujon <laurent@apache.org> Signed-off-by: Dane Pitkin <dpitkin@apache.org>