On reboot, we've encountered an issue where the handler returns null,
causing a null pointer exception in the broadcast receiver.
In this CL, we add a null check and an error message to prevent a sysui
crash.
Bug: 148869042
Test: build, reboot a few times
Change-Id: Iac7f3a538be9a53d4a76926523aa2a3f4f22723d
Merged-In: Ie8a2627004876cf35291d52bd3686a5014498f52
Before the state was update lazily when someone interacted with
appopsmanager.
Since Q the the uid state might change depending on the procState
and hence we might need to trigger the opChanged callbacks when the
procState is applied.
Bug: 148180766
Test: (on master) atest CtsAppOpsTestCases:android.app.appops.cts.ForegroundModeTest
Change-Id: I99720a372db6e79eaba30e4563c09e009cffe86f
Merged-In: Id974769a4e9d89c01890b7557dd93f8444a3908f
Multiple packages might share a UID, but appOpsService might not have
cached the uid->package mapping for those yet. Hence the only way to
list all packages for a uid is to ask package manager.
setUidMode already handled this correctly, hence factor out the code
into notifyOpChangedForAllPkgsInUid and reuse it from
commitUidStatePendingLocked.
Bug: 148180766
Test: (on master) atest CtsAppOpsTestCases:android.app.appops.cts.ForegroundModeTest
Change-Id: I99a8f255a60d3523da7eb36a8f2c9426af1a1fea
Merged-In: I2d5d6c7aa38d201707349a137c9c29b7987775be
Bug: None
Test: I solemnly swear I tested this conflict resolution.
Change-Id: I2d15aaa7402e4e08f1630aa29892ad6cd68bd2b1
Merged-In: I34d1d5f9a751c1d7680a5a5941c39b9fe33a473b
This agent can be attached to an arbitrary Android process with
arguments that cause it to either reset or dump the JaCoCo information
to a provided directory.
Bug: 148178774
Test: manual, used examples in README to test whether it works on a
userdebug_coverage build on cuttlefish
Change-Id: If6cee20046f790676b8085e1ca84652c063295fa
Merged-In: If6cee20046f790676b8085e1ca84652c063295fa
(cherry picked from commit 2d84ae7640)
We can't rely on status bar state changes to update the notification
list. The current user might not be set yet, causing wrong notifications
to become visible.
Fixes: 145135488
Test: manual
Test: atest NotificationStackScrollLayoutTest
Change-Id: I34d1d5f9a751c1d7680a5a5941c39b9fe33a473b
Merged-In: I34d1d5f9a751c1d7680a5a5941c39b9fe33a473b
We updated staged sessions to activation failed state when they
aren't in terminal state, and device received ota and reboot. This
happend before the StagingManager resumes the sessions when
the whole set of parent+child sessions have been restored.
A parent session probably cannot find the child session, and a null
exception could happen.
In this change, we do not destroy child sessions before we destroy
the parent session. We only destroy a child session directly if we
are sure that its parent session doesn't exist.
Bug: 147651771
Test: StagedInstallTest
Change-Id: Iac6489a04df35f851aa18a91e1dde2d73928b8ec
Merged-in: Iac6489a04df35f851aa18a91e1dde2d73928b8ec
(cherry picked from commit 1fc8b36cf3)
am skip reason: Change-Id I58502d1b32d793aba9aa772fa2ad5ac38acca48a with SHA-1 a8fb6dc167 is in history
Change-Id: I957e0de935727d4ccb9263f27c123277329072a0
am skip reason: Change-Id I58502d1b32d793aba9aa772fa2ad5ac38acca48a with SHA-1 a8fb6dc167 is in history
Change-Id: Ia0198d3592672180b0c2f13010d000c9e3c3e058
am skip reason: Change-Id I58502d1b32d793aba9aa772fa2ad5ac38acca48a with SHA-1 ef5220e5b2 is in history
Change-Id: I1e39ae47fabb0eb668ac759f1e164771612c582a
am skip reason: Change-Id I58502d1b32d793aba9aa772fa2ad5ac38acca48a with SHA-1 ef5220e5b2 is in history
Change-Id: I80e44d4cb30a8648df50be2f5fc1b0fd084b3815
am skip reason: Change-Id I58502d1b32d793aba9aa772fa2ad5ac38acca48a with SHA-1 a8fb6dc167 is in history
Change-Id: Ib4651eddc8a8bbf00671515372f987902572424e
am skip reason: Change-Id I58502d1b32d793aba9aa772fa2ad5ac38acca48a with SHA-1 a8fb6dc167 is in history
Change-Id: I205597d434fa161742798c3ec22d39b1b4454908
am skip reason: Change-Id I58502d1b32d793aba9aa772fa2ad5ac38acca48a with SHA-1 a8fb6dc167 is in history
Change-Id: I07cddcbfad7f4841ef99796c8a7a64b9a5ac13c4
am skip reason: Change-Id I58502d1b32d793aba9aa772fa2ad5ac38acca48a with SHA-1 a8fb6dc167 is in history
Change-Id: I1d9a4edd563df9c2a5b40c630517a34a241b3a55
am skip reason: Change-Id I58502d1b32d793aba9aa772fa2ad5ac38acca48a with SHA-1 ce22265eed is in history
Change-Id: I7cbffcbb84841e9faf9f55d8423bb91c6165a83c
am skip reason: Change-Id I58502d1b32d793aba9aa772fa2ad5ac38acca48a with SHA-1 d2a71cc4b8 is in history
Change-Id: I1e92a69fbd5f1c2ac656bfb8f7f8e62b1ce402a0
By default, PR_SET_DUMPABLE is 0 for zygote spawned apps, except in the
following circumstances:
1. ro.debuggable=1 (global debuggable enabled, i.e., userdebug or eng builds).
2. android:debuggable="true" in the manifest for an individual application.
3. An app which explicitly calls prctl(PR_SET_DUMPABLE, 1).
4. GraphicsEnv calls prctl(PR_SET_DUMPABLE, 1) in the presence of
<meta-data android:name="com.android.graphics.injectLayers.enable"
android:value="true"/>
in the application manifest.
So checking both ro.debuggable=1 and PR_GET_DUMPABLE is redundant.
Bug: b/144186877, b/148566223
Test: CtsAngleIntegrationHostTestCases
Test: CtsRootlessGpuDebugHostTest
Change-Id: Ica49254df2c7c090808411935cdeb8efd4e3cb51
Merged-In: Ica49254df2c7c090808411935cdeb8efd4e3cb51
(cherry picked from commit 097a3062b9)
This addresses an issue where toasts will be hidden due to the setting
of the LAYOUT_HIDE_NAVIGATION flag.
Bug: 148180738
Test: manual (adb shell settings put global policy_control "immersive.navigation=*" then try to show a toast with gravity top)
Change-Id: Ic47edc5423c4daf373fc3a8bfc30af15cadd6d90
am skip reason: Change-Id Ia938502d2443f5a6de6a3cabdb7ce1d41d3ff6d1 with SHA-1 0a8a1e9d40 is in history
Change-Id: Ie771ffdfc4cfc2d58d0b74ea29f56655462924ca