Setting the time-of-day clock is still useful on systems where the RTC
device is not yet brought up or otherwise unavailable. This matches the
in-kernel behavior of the Android alarm driver.
Change-Id: I6d4fdadab12e241ada7419425efd55bd13873c55
Signed-off-by: Greg Hackmann <ghackmann@google.com>
On devices using /dev/rtc instead of /dev/alarm, updating the
time-of-day clock and RTC are separate syscalls. Hence the clock and
RTC could be left in inconsistent states if two threads called
SystemClock.setCurrentTimeMillis() simultaneously.
By moving this code into AlarmManagerService, we can put a global lock
around AlarmManagerService.setTime() and prevent the race condition.
Note that access to SystemClock.setCurrentTimeMillis() is now gated by
android.permission.SET_TIME, where before it was gated by filesystem
permissions (i.e., could the process write to /dev/alarm or /dev/rtc).
Change-Id: Ia34899a4cde983656305fd2ef466dfe908ed23c8
Signed-off-by: Greg Hackmann <ghackmann@google.com>
Those intent handlers are persistent preferences. They will remain the default intent
handler even if the set of potential event handlers for the intent filter changes
and if the intent preferences are reset.
Change-Id: Id0cfae46f93c10d89e441f272096a205ec518dd0
JNITest class is no longer actively used. This patch
removes the class (java and jni) files.
JNI interfaces and calls are extensively tested in
the art unit tests (art/tests) and in cts (see
CtsJniTestCases).
Change-Id: I62f7c72deb5d206fa3f545ae39a9cb9011110d0a
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
Using reinterpret_cast allows conversions between pointer types
and integers which don't have the same size. The corresponding
flags is -Wint-to-pointer-cast.
Change-Id: I8ff0c79d235fa6d07b8d9305edc185d946d5133d
Signed-off-by: Kévin PETIT <kevin.petit@arm.com>
Changes in this patch include
[x] Long(64-bit) is used to store native pointers in
AssetAtlasService and related classes as they can be 64-bit.
[x] Some minor changes have been done to conform with
standard JNI practice (e.g. use of jint instead of int
in JNI function prototypes)
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
(cherry-picked from 4de3f481bc59ab4b766dc027e41aff7cda9d62f7)
Change-Id: If22daf40eef46f8df9f94d65ddcc52c45b3acf2a
Constants are derived from this doc:
https://docs.google.com/a/google.com/document/d/1lmlFcTeefLDRp_bpMrXk3yK9nKxoTVfpcShanpLxiMg/edit#heading=h.b16863tyyjzv
That doc contains the full explanation of these changes.
I'm making this change on behalf of {elmas,pengr} who don't have
android source access but designed this in collaboration with
rharagutchi on the play music team. I'll probably have to route any
significant questions through them.
Bug: 12874557
Change-Id: I85a4bee57a2bde519da0dc6de2cad9d036da225c
Bug: 13077993
If an EDU device was marked as prohibited from adding/removing accounts, it was throwing
an error but still continuing to remove the account. This fixes the problem by aborting
the removeAccount steps.
Change-Id: Ie7f157c5397a7391aab6f37c8a4331479f1b451b