Disable Runtime#load/loadLibrary(String,ClassLoader) in >N
Runtime#load/loadLibrary are private and deprecated methods.
Still, many apps use reflection to use them. If app is
targeting API level > 24, both methods will throw
a RuntimeException.
This is a second attempt, with a working tests.
Bug: 25859957
Change-Id: I9808831493f297f3551884ec8f1e6a079476a803
Test: libcore.java.lang.OldRuntimeTest
(cherry picked from commit 8e99fd200798d3d115745bacfb853209af3501cd and 6ee825e4decc602f3e6ca6e5b084382fc6f60bb5)
2 files changed