Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b66d9fc3 authored by Brad Ebinger's avatar Brad Ebinger Committed by Android (Google) Code Review
Browse files

Merge "Fix ComponentName NPE when binding to InCallService" into nyc-mr1-dev

parents 1f526d55 abe06d37
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -912,8 +912,12 @@ public final class InCallController extends CallsManagerListenerBase {
        List<InCallServiceInfo> list = getInCallServiceComponents(componentName, type);
        if (list != null && !list.isEmpty()) {
            return list.get(0);
        } else {
            // Last Resort: Try to bind to the ComponentName given directly.
            Log.e(this, new Exception(), "Package Manager could not find ComponentName: "
                    + componentName +". Trying to bind anyway.");
            return new InCallServiceInfo(componentName, false);
        }
        return null;
    }

    private InCallServiceInfo getInCallServiceComponent(String packageName, int type) {