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

Unified Diff: content/app/android/library_loader_hooks.cc

Issue 59533009: Check library version and handle library load errors (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 1 month 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/app/android/library_loader_hooks.cc
diff --git a/content/app/android/library_loader_hooks.cc b/content/app/android/library_loader_hooks.cc
index a42474879c6893ec3486ff22f504fc4ae3eef176..7b3f65835e0f5f611e63fe707402196ffb518b0f 100644
--- a/content/app/android/library_loader_hooks.cc
+++ b/content/app/android/library_loader_hooks.cc
@@ -36,6 +36,7 @@ namespace content {
namespace {
base::AtExitManager* g_at_exit_manager = NULL;
+std::string library_version_name = "";
joth 2013/11/11 20:28:56 g_library_version_name...
joth 2013/11/11 20:28:56 this is a global C++ object, not allowed by style
aberent 2013/11/13 20:20:52 I have changed it to a const char *, but I am sett
}
bool EnsureJniRegistered(JNIEnv* env) {
@@ -146,4 +147,12 @@ bool RegisterLibraryLoaderEntryHook(JNIEnv* env) {
return RegisterNativesImpl(env);
}
+void SetVersionName(const std::string & version_name) {
joth 2013/11/11 20:28:56 not space before & (and in header)
aberent 2013/11/13 20:20:52 Done.
+ library_version_name = version_name;
+}
+
+jstring GetVersionName(JNIEnv* env, jclass clazz) {
+ return env->NewStringUTF(library_version_name.c_str());
+}
+
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698