commit | 7e9659fadc308cbe2f33d9915f3461bead791386 | [log] [tgz] |
---|---|---|
author | Julia Reynolds <juliacr@google.com> | Fri Mar 30 10:19:35 2018 -0400 |
committer | Julia Reynolds <juliacr@google.com> | Fri Mar 30 10:19:35 2018 -0400 |
tree | b7de33cd63b87fe57fbbebd3cf55edc9efa262e0 | |
parent | 24f221350569a6820da1d205fdd1cd9d162dba1d [diff] |
Catch unbinding errors Test: none Change-Id: Ia8ca50c7c55b86fac84a04a5e4ef2aa36ae6bf6e Fixes: 72206319
diff --git a/services/core/java/com/android/server/notification/ManagedServices.java b/services/core/java/com/android/server/notification/ManagedServices.java index b7842d5..d5a32aa 100644 --- a/services/core/java/com/android/server/notification/ManagedServices.java +++ b/services/core/java/com/android/server/notification/ManagedServices.java
@@ -982,7 +982,11 @@ Slog.w(TAG, getCaption() + " binding died: " + name); synchronized (mMutex) { mServicesBinding.remove(servicesBindingTag); - mContext.unbindService(this); + try { + mContext.unbindService(this); + } catch (IllegalArgumentException e) { + Slog.e(TAG, "failed to unbind " + name, e); + } if (!mServicesRebinding.contains(servicesBindingTag)) { mServicesRebinding.add(servicesBindingTag); mHandler.postDelayed(new Runnable() {