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

Commit 756ccba9 authored by fionaxu's avatar fionaxu Committed by android-build-merger
Browse files

Do not allow premium SMS during SuW am: d8764991 am: b6cb6ad7 am:...

Do not allow premium SMS during SuW am: d8764991 am: b6cb6ad7 am: b63de969 am: aa6025d0 am: 6ac76ba0 am: bd6080f6 am: 23e85fe0 am: 7933d601 am: cd86f722
am: 32388fe9

Change-Id: Iaa3cbf7ea815831564a9f1c0e4bbcc875e6d242f
parents 014d1eb9 32388fe9
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1047,6 +1047,12 @@ public abstract class SMSDispatcher extends Handler {
                return true;    // not a premium short code
            }

            // Do not allow any premium sms during SuW
            if (Settings.Global.getInt(mResolver, Settings.Global.DEVICE_PROVISIONED, 0) == 0) {
                Rlog.e(TAG, "Can't send premium sms during Setup Wizard");
                return false;
            }

            // Wait for user confirmation unless the user has set permission to always allow/deny
            int premiumSmsPermission = mUsageMonitor.getPremiumSmsPermission(
                    tracker.mAppInfo.packageName);