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

Unified Diff: chrome/browser/android/chrome_backup_agent.cc

Issue 2877703006: Add functions to convert boolean jni array. (Closed)
Patch Set: Created 3 years, 7 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
« no previous file with comments | « base/android/jni_array_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/chrome_backup_agent.cc
diff --git a/chrome/browser/android/chrome_backup_agent.cc b/chrome/browser/android/chrome_backup_agent.cc
index 965f53c8b506cbef0bb0e733a910ff4dec4b4615..7ce2ac6500faa92a887a8368f4c693af11676ca4 100644
--- a/chrome/browser/android/chrome_backup_agent.cc
+++ b/chrome/browser/android/chrome_backup_agent.cc
@@ -74,7 +74,8 @@ static void SetBoolBackupPrefs(
const base::android::JavaParamRef<jbooleanArray>& values) {
std::vector<std::string> pref_names;
base::android::AppendJavaStringArrayToStringVector(env, names, &pref_names);
- jboolean* pref_values = env->GetBooleanArrayElements(values, nullptr);
+ std::vector<bool> pref_values;
+ JavaBooleanArrayToBoolVector(env, values, &pref_values);
std::unordered_set<std::string> valid_prefs(
std::begin(backed_up_preferences_), std::end(backed_up_preferences_));
« no previous file with comments | « base/android/jni_array_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698