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

Issue 1008363004: Fix invalid class names passed to ClassLoader.loadClass. (Closed)

Created:
5 years, 9 months ago by Torne
Modified:
5 years, 9 months ago
Reviewers:
rmcilroy
CC:
chromium-reviews, erikwright+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix invalid class names passed to ClassLoader.loadClass. Substitute slashes for dots in the class name if we are going to pass it to ClassLoader.loadClass via JNI, instead of calling JNIEnv::FindClass. This avoids spamming the log with warnings from Dalvik about invalid class names; it was working correctly anyway due to implementation details of the VM, but we shouldn't be doing this. This is not the ideal solution to the problem but is a relatively safe and isolated fix we can cherrypick to a release branch while we work on a better one. BUG=461773 R=rmcilroy Committed: https://crrev.com/c16354c567b13a6ce3f9b3d8e4c3af61ee3b8c71 Cr-Commit-Position: refs/heads/master@{#320816}

Patch Set 1 #

Total comments: 4

Patch Set 2 : Address nits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+16 lines, -1 line) Patch
M base/android/jni_android.cc View 1 1 chunk +16 lines, -1 line 0 comments Download

Messages

Total messages: 8 (2 generated)
Torne
5 years, 9 months ago (2015-03-16 18:08:03 UTC) #1
rmcilroy
lgtm once comments are addressed, thanks. https://codereview.chromium.org/1008363004/diff/1/base/android/jni_android.cc File base/android/jni_android.cc (right): https://codereview.chromium.org/1008363004/diff/1/base/android/jni_android.cc#newcode167 base/android/jni_android.cc:167: // JNI generator ...
5 years, 9 months ago (2015-03-16 18:13:16 UTC) #2
Torne
https://codereview.chromium.org/1008363004/diff/1/base/android/jni_android.cc File base/android/jni_android.cc (right): https://codereview.chromium.org/1008363004/diff/1/base/android/jni_android.cc#newcode167 base/android/jni_android.cc:167: // JNI generator to generate dot-separated names. On 2015/03/16 ...
5 years, 9 months ago (2015-03-16 20:53:30 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1008363004/20001
5 years, 9 months ago (2015-03-16 20:54:35 UTC) #6
commit-bot: I haz the power
Committed patchset #2 (id:20001)
5 years, 9 months ago (2015-03-16 22:53:39 UTC) #7
commit-bot: I haz the power
5 years, 9 months ago (2015-03-16 22:55:09 UTC) #8
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/c16354c567b13a6ce3f9b3d8e4c3af61ee3b8c71
Cr-Commit-Position: refs/heads/master@{#320816}

Powered by Google App Engine
This is Rietveld 408576698