Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove SoLoader.loadLibraryUnsafe usage in NativeLibrary.java
Summary: **Change**: This diff refactors of the class `NativeLibrary` so that you pass both `List<String> libraryNames`(the libraries to be loaded) and `List<Runnable> libraryLoaders` (list of `Runnable` to invoke `SoLoader.loadLibrary`) to the constructor of `NativeLibrary`. **Context**: The change is motivated by testing delete dead native libraries in postprocessor on instagram and barcelona for android. This can be achieved by using redex to track which libraries are loaded by SoLoader.loadLibrary D63471299 by looking at constant string passed to the method. When SoLoader.loadLibrary is called on non-constant string variable, we replace it with SoLoader.loadLibraryUnsafeD63471297. To make sure we can correctly compute the dead native libs in the postprocessor D64178470, this diff refactor the code to remove usage of loadLibraryUnsafe for instagram and barcleona. Reviewed By: NTillmann Differential Revision: D68152321 fbshipit-source-id: 3dd099575e18bc2d6be347d0848bbe6ac954faa8
- Loading branch information