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

Unified Diff: base/android/jni_array.cc

Issue 7491099: Update base/android to use new ScopedJava(Global)Reference (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Also fix license headers Created 9 years, 4 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.h ('k') | base/android/path_utils.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/android/jni_array.cc
diff --git a/base/android/jni_array.cc b/base/android/jni_array.cc
index 9555abc2232787ffad38bfcac11954349d870014..409b44abf77a17be459bc7916c6e2dc638bc9077 100644
--- a/base/android/jni_array.cc
+++ b/base/android/jni_array.cc
@@ -1,10 +1,11 @@
-// Copyright 2011 Google Inc. All Rights Reserved.
-// Author: michaelbai@google.com (Tao Bai)
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
#include "base/android/jni_array.h"
-#include "base/android/auto_jobject.h"
#include "base/android/jni_android.h"
+#include "base/android/scoped_java_reference.h"
#include "base/logging.h"
namespace base {
@@ -37,7 +38,7 @@ jobjectArray ToJavaArrayOfByteArray(JNIEnv* env,
return NULL;
for (size_t i = 0; i < count; ++i) {
- AutoJObject byte_array = AutoJObject::FromLocalRef(env, ToJavaByteArray(env,
+ ScopedJavaReference<jobject> byte_array(env, ToJavaByteArray(env,
reinterpret_cast<const uint8*>(v[i].data()), v[i].length()));
if (!byte_array.obj()) {
env->DeleteLocalRef(joa);
« no previous file with comments | « base/android/jni_array.h ('k') | base/android/path_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698