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

Unified Diff: chrome/android/webapk/shell_apk/src/org/chromium/webapk/shell_apk/WebApkSandboxedProcessService.java

Issue 2699443003: webapk: Don't swallow onbind exceptions (Closed)
Patch Set: Created 3 years, 10 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/webapk/shell_apk/src/org/chromium/webapk/shell_apk/WebApkSandboxedProcessService.java
diff --git a/chrome/android/webapk/shell_apk/src/org/chromium/webapk/shell_apk/WebApkSandboxedProcessService.java b/chrome/android/webapk/shell_apk/src/org/chromium/webapk/shell_apk/WebApkSandboxedProcessService.java
index 51fdd2af21d524b2c42d576b5ff3b29313db9792..58219606e0dcd002c56861c76836d0314f018b27 100644
--- a/chrome/android/webapk/shell_apk/src/org/chromium/webapk/shell_apk/WebApkSandboxedProcessService.java
+++ b/chrome/android/webapk/shell_apk/src/org/chromium/webapk/shell_apk/WebApkSandboxedProcessService.java
@@ -10,6 +10,7 @@ import android.content.Intent;
import android.os.IBinder;
import android.util.Log;
+import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
/**
@@ -56,16 +57,15 @@ public class WebApkSandboxedProcessService extends Service {
// scratch every time.
stopSelf();
try {
- Method bindMethod = mChildProcessServiceImplClass.getMethod(
- "bind", Intent.class, int.class);
+ Method bindMethod =
+ mChildProcessServiceImplClass.getMethod("bind", Intent.class, int.class);
int hostBrowserUid = WebApkUtils.getHostBrowserUid(this);
assert hostBrowserUid >= 0;
return (IBinder) bindMethod.invoke(
mChildProcessServiceImplInstance, intent, hostBrowserUid);
- } catch (Exception e) {
- Log.v(TAG, "Unable to bind to the WebApkSandboxedProcessService.", e);
+ } catch (NoSuchMethodException | IllegalAccessException | InvocationTargetException e) {
+ throw new RuntimeException(e);
}
- return null;
}
@Override
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698