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

Commit 054e6667 authored by Tyler Gunn's avatar Tyler Gunn
Browse files

Ensure phone state broadcast does not include 3p app addresses.

Do not include the address reported by an app implementing the self-mgd
ConnectionService API.  Aothough we want to report the fact we're in
a call using the phone state broadcast, it is not desirable to include
the call identifier information reported by a third party app.  The phone
number is included in the phone state broadcast to help wearable
companion apps and call blocking apps, for example, operate.  Since none
of these apps can operate on self-managed calls it makes no sense to
expose the number to these apps.

Test: Manual test using test app.
Bug: 79343159
Change-Id: I29eca34bba5e1ec636fdc245bb1221b2f63bbcb1
parent 195e669f
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -106,7 +106,9 @@ final class PhoneStateBroadcaster extends CallsManagerListenerBase {
        mCurrentState = phoneState;

        String callHandle = null;
        if (call.getHandle() != null) {
        // Only report phone numbers in phone state broadcast for regular mobile calls; do not
        // include numbers from 3rd party apps.
        if (!call.isSelfManaged() && call.getHandle() != null) {
            callHandle = call.getHandle().getSchemeSpecificPart();
        }