Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(395)

Unified Diff: content/shell/android/browsertests_apk/content_browser_tests_android.cc

Issue 141223002: Move the android library loader from content to base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix final nits Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/shell/android/browsertests_apk/content_browser_tests_android.cc
diff --git a/content/shell/android/browsertests_apk/content_browser_tests_android.cc b/content/shell/android/browsertests_apk/content_browser_tests_android.cc
index 0acff508aea9980f1c03ff0947e5f38368a7fb60..d4dd0b2221e12c8a3cd7e25f2df7546baaa6efe4 100644
--- a/content/shell/android/browsertests_apk/content_browser_tests_android.cc
+++ b/content/shell/android/browsertests_apk/content_browser_tests_android.cc
@@ -12,6 +12,7 @@
#include "base/android/fifo_utils.h"
#include "base/android/jni_android.h"
#include "base/android/jni_string.h"
+#include "base/android/library_loader/library_loader_hooks.h"
#include "base/android/scoped_java_ref.h"
#include "base/base_switches.h"
#include "base/command_line.h"
@@ -98,10 +99,13 @@ static void RunTests(JNIEnv* env,
// This is called by the VM when the shared library is first loaded.
JNI_EXPORT jint JNI_OnLoad(JavaVM* vm, void* reserved) {
+
+ base::android::SetLibraryLoadedHook(&content::LibraryLoaded);
+
base::android::InitVM(vm);
JNIEnv* env = base::android::AttachCurrentThread();
- if (!content::RegisterLibraryLoaderEntryHook(env))
+ if (!base::android::RegisterLibraryLoaderEntryHook(env))
return -1;
if (!content::android::RegisterShellJni(env))

Powered by Google App Engine
This is Rietveld 408576698