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

Commit 25c0e878 authored by Julia Reynolds's avatar Julia Reynolds
Browse files

Post system_server toasts as system_server

Test: atest com.android.cts.devicepolicy.MixedProfileOwnerTest#testPrintingPolicy
Change-Id: I7ac337dee93bc3843ef2440c2ce7a3b6f7ce094e
Fixes: 119169211
parent 05fa5e1c
Loading
Loading
Loading
Loading
+5 −4
Original line number Diff line number Diff line
@@ -146,13 +146,14 @@ public final class PrintManagerService extends SystemService {
                final long identity = Binder.clearCallingIdentity();
                try {
                    disabledMessage = dpmi.getPrintingDisabledReasonForUser(callingUserId);
                } finally {
                    Binder.restoreCallingIdentity(identity);
                }

                    if (disabledMessage != null) {
                        Toast.makeText(mContext, Looper.getMainLooper(), disabledMessage,
                                Toast.LENGTH_LONG).show();
                    }
                } finally {
                    Binder.restoreCallingIdentity(identity);
                }
                try {
                    adapter.start();
                } catch (RemoteException re) {