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

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

Issue 2667263002: android: Move JavaExceptionReporter to base (Closed)
Patch Set: maindex Created 3 years, 11 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 | « chrome/browser/android/java_exception_reporter.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/java_exception_reporter.cc
diff --git a/chrome/browser/android/java_exception_reporter.cc b/chrome/browser/android/java_exception_reporter.cc
deleted file mode 100644
index d76cb238515adbf02fc0c65a369089c234c1fe74..0000000000000000000000000000000000000000
--- a/chrome/browser/android/java_exception_reporter.cc
+++ /dev/null
@@ -1,50 +0,0 @@
-// Copyright 2015 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 "chrome/browser/android/java_exception_reporter.h"
-
-#include "base/android/build_info.h"
-#include "base/android/jni_android.h"
-#include "base/android/jni_string.h"
-#include "base/debug/dump_without_crashing.h"
-#include "jni/JavaExceptionReporter_jni.h"
-
-using base::android::JavaParamRef;
-
-namespace chrome {
-namespace android {
-
-void InitJavaExceptionReporter() {
- JNIEnv* env = base::android::AttachCurrentThread();
- Java_JavaExceptionReporter_installHandler(env);
-}
-
-void ReportJavaException(JNIEnv* env,
- const JavaParamRef<jclass>& jcaller,
- const JavaParamRef<jthrowable>& e) {
- // Set the exception_string in BuildInfo so that breakpad can read it.
- base::android::BuildInfo::GetInstance()->SetJavaExceptionInfo(
- base::android::GetJavaExceptionInfo(env, e));
- base::debug::DumpWithoutCrashing();
- base::android::BuildInfo::GetInstance()->ClearJavaExceptionInfo();
-}
-
-void ReportJavaStackTrace(JNIEnv* env,
- const JavaParamRef<jclass>& jcaller,
- const JavaParamRef<jstring>& stackTrace) {
- base::android::BuildInfo::GetInstance()->SetJavaExceptionInfo(
- ConvertJavaStringToUTF8(stackTrace));
- base::debug::DumpWithoutCrashing();
- base::android::BuildInfo::GetInstance()->ClearJavaExceptionInfo();
-}
-
-bool RegisterJavaExceptionReporterJni(JNIEnv* env) {
- return RegisterNativesImpl(env);
-}
-
-
-} // namespace android
-} // namespace chrome
-
-
« no previous file with comments | « chrome/browser/android/java_exception_reporter.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698