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

Issue 59533009: Check library version and handle library load errors (Closed)

Created:
7 years, 1 month ago by aberent
Modified:
7 years ago
Reviewers:
joth, Yaron, piman
CC:
chromium-reviews, tim+watch_chromium.org, craigdh+watch_chromium.org, haitaol+watch_chromium.org, jam, joi+watch-content_chromium.org, darin-cc_chromium.org, yfriedman+watch_chromium.org, ilevy-cc_chromium.org, bulach+watch_chromium.org, klundberg+watch_chromium.org, rsimha+watch_chromium.org, android-webview-reviews_chromium.org, jochen+watch_chromium.org, frankf+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

Check library version and handle library load errors This CL modifies the build to incorporate the expected C++ library version in the Java code. This is then checked when the library is loaded, to make sure that the C++ and Java builds match. This CL also implements error handling when library loads fail or the loaded version doesn't match the expected version. BUG=311644 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=237779

Patch Set 1 #

Total comments: 16

Patch Set 2 : Answer review comments #

Total comments: 19

Patch Set 3 : Respond to second round of review comments. #

Total comments: 10

Patch Set 4 : Fix nits #

Patch Set 5 : Rebase to allow clean commit. #

Patch Set 6 : Fix merge error #

Patch Set 7 : Add calls to System.exit() to findbugs_exclude.xml #

Patch Set 8 : Fix WebView version name/number #

Patch Set 9 : Fix BrowserStartupControllerTest #

Unified diffs Side-by-side diffs Delta from patch set Stats (+337 lines, -139 lines) Patch
M android_webview/java/generated_src/org/chromium/content/app/NativeLibraries.java View 1 2 3 4 5 6 7 1 chunk +6 lines, -1 line 0 comments Download
M android_webview/java/src/org/chromium/android_webview/AwBrowserProcess.java View 1 1 chunk +5 lines, -3 lines 0 comments Download
M build/android/findbugs_filter/findbugs_exclude.xml View 1 2 3 4 5 6 1 chunk +40 lines, -0 lines 0 comments Download
M build/android/gyp/create_native_libraries_header.py View 1 2 3 3 chunks +15 lines, -9 lines 0 comments Download
M build/java_apk.gypi View 1 2 5 chunks +10 lines, -5 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/sync/ChromiumSyncAdapter.java View 1 2 3 3 chunks +21 lines, -18 lines 0 comments Download
M chrome/android/testshell/java/src/org/chromium/chrome/testshell/ChromiumTestShellActivity.java View 1 2 3 4 2 chunks +8 lines, -1 line 0 comments Download
M chrome/android/testshell/java/src/org/chromium/chrome/testshell/signin/AccountsChangedReceiver.java View 2 chunks +8 lines, -1 line 0 comments Download
M chrome/android/testshell/javatests/src/org/chromium/chrome/testshell/ChromiumTestShellTestBase.java View 1 2 3 4 5 4 chunks +10 lines, -2 lines 0 comments Download
M chrome/app/android/chrome_android_initializer.cc View 1 2 chunks +6 lines, -0 lines 0 comments Download
M chrome/chrome_android.gypi View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M content/app/android/library_loader_hooks.cc View 1 2 3 2 chunks +9 lines, -0 lines 0 comments Download
M content/public/android/java/src/org/chromium/content/app/ChildProcessService.java View 1 chunk +1 line, -1 line 0 comments Download
M content/public/android/java/src/org/chromium/content/app/LibraryLoader.java View 1 2 3 4 chunks +19 lines, -5 lines 0 comments Download
M content/public/android/java/src/org/chromium/content/browser/BrowserStartupController.java View 1 2 3 5 chunks +19 lines, -27 lines 0 comments Download
M content/public/android/java/templates/NativeLibraries.template View 1 1 chunk +10 lines, -1 line 0 comments Download
M content/public/android/java/templates/native_libraries_array.h View 1 2 3 1 chunk +12 lines, -0 lines 0 comments Download
A + content/public/android/java/templates/native_libraries_version.h View 1 2 1 chunk +4 lines, -3 lines 0 comments Download
M content/public/android/javatests/src/org/chromium/content/browser/BrowserStartupControllerTest.java View 1 2 3 4 5 6 7 8 16 chunks +92 lines, -43 lines 0 comments Download
M content/public/app/android_library_loader_hooks.h View 1 2 3 1 chunk +5 lines, -0 lines 0 comments Download
M content/public/common/result_codes_list.h View 1 1 chunk +6 lines, -0 lines 0 comments Download
M content/shell/android/browsertests_apk/src/org/chromium/content_browsertests_apk/ContentBrowserTestsActivity.java View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M content/shell/android/shell_apk/src/org/chromium/content_shell_apk/ContentShellActivity.java View 1 2 3 4 5 2 chunks +28 lines, -18 lines 0 comments Download
M testing/android/java/src/org/chromium/native_test/ChromeNativeTestActivity.java View 1 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 20 (0 generated)
aberent
yfriedman@chromium.org: Please review all changes. piman@chromium.org: Please review, as OWNER, changes to android_library_loader_hooks.h and results_code_list.h ...
7 years, 1 month ago (2013-11-11 20:13:27 UTC) #1
joth
https://codereview.chromium.org/59533009/diff/1/android_webview/java/generated_src/org/chromium/content/app/NativeLibraries.java File android_webview/java/generated_src/org/chromium/content/app/NativeLibraries.java (right): https://codereview.chromium.org/59533009/diff/1/android_webview/java/generated_src/org/chromium/content/app/NativeLibraries.java#newcode21 android_webview/java/generated_src/org/chromium/content/app/NativeLibraries.java:21: static String versionName = ""; nit: sVersionName (and libraries ...
7 years, 1 month ago (2013-11-11 20:28:56 UTC) #2
Yaron
https://codereview.chromium.org/59533009/diff/1/android_webview/java/src/org/chromium/android_webview/AwBrowserProcess.java File android_webview/java/src/org/chromium/android_webview/AwBrowserProcess.java (right): https://codereview.chromium.org/59533009/diff/1/android_webview/java/src/org/chromium/android_webview/AwBrowserProcess.java#newcode49 android_webview/java/src/org/chromium/android_webview/AwBrowserProcess.java:49: if( !BrowserStartupController.get(context).startBrowserProcessesSync( On 2013/11/11 20:28:56, joth wrote: > this ...
7 years, 1 month ago (2013-11-12 02:58:18 UTC) #3
piman
For content/, what joth@ said, after that LGTM.
7 years, 1 month ago (2013-11-12 19:27:19 UTC) #4
aberent
https://codereview.chromium.org/59533009/diff/1/android_webview/java/generated_src/org/chromium/content/app/NativeLibraries.java File android_webview/java/generated_src/org/chromium/content/app/NativeLibraries.java (right): https://codereview.chromium.org/59533009/diff/1/android_webview/java/generated_src/org/chromium/content/app/NativeLibraries.java#newcode21 android_webview/java/generated_src/org/chromium/content/app/NativeLibraries.java:21: static String versionName = ""; On 2013/11/11 20:28:56, joth ...
7 years, 1 month ago (2013-11-13 20:20:52 UTC) #5
Yaron
https://codereview.chromium.org/59533009/diff/110001/build/java_apk.gypi File build/java_apk.gypi (left): https://codereview.chromium.org/59533009/diff/110001/build/java_apk.gypi#oldcode64 build/java_apk.gypi:64: 'app_manifest_version_code%': '<(android_app_version_code)', I think this is breaking some people. ...
7 years, 1 month ago (2013-11-16 00:10:25 UTC) #6
aberent
New patch follows. https://codereview.chromium.org/59533009/diff/110001/build/java_apk.gypi File build/java_apk.gypi (left): https://codereview.chromium.org/59533009/diff/110001/build/java_apk.gypi#oldcode64 build/java_apk.gypi:64: 'app_manifest_version_code%': '<(android_app_version_code)', On 2013/11/16 00:10:26, Yaron ...
7 years, 1 month ago (2013-11-18 15:11:37 UTC) #7
aberent
https://codereview.chromium.org/59533009/diff/110001/build/java_apk.gypi File build/java_apk.gypi (right): https://codereview.chromium.org/59533009/diff/110001/build/java_apk.gypi#newcode246 build/java_apk.gypi:246: # '<(native_libraries_template_data_file)', On 2013/11/18 15:11:37, aberent wrote: > On ...
7 years, 1 month ago (2013-11-18 18:26:52 UTC) #8
Yaron
lgtm https://codereview.chromium.org/59533009/diff/110001/content/app/android/library_loader_hooks.cc File content/app/android/library_loader_hooks.cc (right): https://codereview.chromium.org/59533009/diff/110001/content/app/android/library_loader_hooks.cc#newcode5 content/app/android/library_loader_hooks.cc:5: #include <string.h> On 2013/11/16 00:10:26, Yaron wrote: > ...
7 years, 1 month ago (2013-11-18 19:07:54 UTC) #9
joth
aw/ lgtm I skimmed over all of content/ as well, but let me know if ...
7 years, 1 month ago (2013-11-18 19:45:22 UTC) #10
aberent
https://codereview.chromium.org/59533009/diff/250001/build/android/gyp/create_native_libraries_header.py File build/android/gyp/create_native_libraries_header.py (right): https://codereview.chromium.org/59533009/diff/250001/build/android/gyp/create_native_libraries_header.py#newcode9 build/android/gyp/create_native_libraries_header.py:9: This header should contain the list of native libraries ...
7 years ago (2013-11-25 18:31:41 UTC) #11
Yaron
still lgtm
7 years ago (2013-11-25 23:22:07 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/aberent@chromium.org/59533009/450001
7 years ago (2013-11-27 12:16:48 UTC) #13
commit-bot: I haz the power
Retried try job too often on android_dbg for step(s) slave_steps http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=android_dbg&number=126837
7 years ago (2013-11-27 13:13:37 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/aberent@chromium.org/59533009/470001
7 years ago (2013-11-27 13:56:24 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/aberent@chromium.org/59533009/490001
7 years ago (2013-11-27 17:02:32 UTC) #16
commit-bot: I haz the power
Retried try job too often on android_aosp for step(s) compile http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=android_aosp&number=30312
7 years ago (2013-11-27 18:16:59 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/aberent@chromium.org/59533009/510001
7 years ago (2013-11-28 09:20:45 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/aberent@chromium.org/59533009/530001
7 years ago (2013-11-28 12:22:47 UTC) #19
commit-bot: I haz the power
7 years ago (2013-11-28 14:28:54 UTC) #20
Message was sent while issue was closed.
Change committed as 237779

Powered by Google App Engine
This is Rietveld 408576698