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

Unified Diff: android_webview/native/android_protocol_handler.cc

Issue 1308363003: Revert of jni_generator: Make all object-returning natives return ScopedJavaLocalRef. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 | « no previous file | android_webview/native/aw_contents_statics.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/native/android_protocol_handler.cc
diff --git a/android_webview/native/android_protocol_handler.cc b/android_webview/native/android_protocol_handler.cc
index e25b36dae3efbf402399c696361e81030e974742..be3376cc976e0f2815e0d2b211c10e1ded01d171 100644
--- a/android_webview/native/android_protocol_handler.cc
+++ b/android_webview/native/android_protocol_handler.cc
@@ -281,14 +281,16 @@
}
}
-static ScopedJavaLocalRef<jstring> GetAndroidAssetPath(JNIEnv* env,
- jclass /*clazz*/) {
- return ConvertUTF8ToJavaString(env, android_webview::kAndroidAssetPath);
-}
-
-static ScopedJavaLocalRef<jstring> GetAndroidResourcePath(JNIEnv* env,
- jclass /*clazz*/) {
- return ConvertUTF8ToJavaString(env, android_webview::kAndroidResourcePath);
+static jstring GetAndroidAssetPath(JNIEnv* env, jclass /*clazz*/) {
+ // OK to release, JNI binding.
+ return ConvertUTF8ToJavaString(
+ env, android_webview::kAndroidAssetPath).Release();
+}
+
+static jstring GetAndroidResourcePath(JNIEnv* env, jclass /*clazz*/) {
+ // OK to release, JNI binding.
+ return ConvertUTF8ToJavaString(
+ env, android_webview::kAndroidResourcePath).Release();
}
} // namespace android_webview
« no previous file with comments | « no previous file | android_webview/native/aw_contents_statics.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698