setDataSource(String) throws an IllegalArgumentException
when an IOException or FileNotFoundException occurs, but doesn't
close FileDescriptor accordingly.
Change-Id: Ib6e0f1418afeeb19e03abd4bedb4cc845a58b6b4
Add system properties to support zygote-started method tracing.
These are needed as the limit on system properties does not allow
the reuse of the runtime extra options system property.
Bug: 21760614
(cherry picked from commit 98f406f6f31660d0f5ee32113ffadc720b426dc6)
Change-Id: I3785cc5715acadbee81ef7b45081ed780f1351d3
The new option "--track-allocation" is to work with the new
allocation tracker in ART.
Bug:20037135
Change-Id: Ic5f8945ab4c1f167c27b05ad0d11d04bac680c1f
The overlaytests testrunner.py script wants to invoke adb shell md5sum
to compute the md5 of a file, but wrongly invokes it as md5. Maybe
it used to have that name, but it doesn't exist under that name in master.
Fix it.
Change-Id: I3ec4be162fab0cd3915f010f9b1add37b5397973
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
While in computing surface crop region, magnification specs are
not applied to surface insets from LayoutParams.
So, in case magnification specs are set,
surface crop region should be calculated considering scale factor.
(For instance, using TouchZoom in Accessibility
at AppsPermissionActivity in market app)
Bug: 20863078
Change-Id: I9e7e21e502b29208f2856918d6fcda050f515595
Signed-off-by: Seunghyun Lee <seunghyun85.lee@lge.com>
This code had an undeclared dependency on libsrec_jni which
we no longer build.
bug: 21855957
(cherry picked from commit b39dfe87b89e3773910202f2e94b9860236551d9)
Change-Id: I6c97f22916766714ae899cf51f1b56cde308af8e
getEntryInfo crashes on 64-bit devices because "long" types
were being passed int pointers (that pointed to a stack frame)
that were reinterpret_cast'ed to long* (sigh.). To fix this issue
once and for all, use types with explicitly defined widths.
This change also removes some dead invariant checking from
Asset.cpp instead of cleaning it up.
Note that we've introduced a wart in NativeLibraryHelper, where
we need to deal with zlib's uLong type, which is "at least 32 bits
wide".
bug: 21622286
(cherry picked from commit 4600dd053dbdbd4b95f3b11057a1cc55b99f9c77)
Change-Id: I7886cb37a229cc27c625699c80e6a6a6117d2203
If an application has native code (and primary abi)
include path to corresponding folder inside apk-file
to ldLibraryPath when constructing PathClassLoader
Bug: 21647354
Bug: 21667767
Bug: 21726698
Bug: 8076853
Change-Id: Ib0a2f01ee69019d3206a00c542bd7d0f58d0c481
(cherry picked from commit e56b3f63e8235ab45e081fc9d3476a3e5248ddde)
Calling println_native with the value of ASSERT will set the abort
message. Unfortunately, there are numerous cases where one thread aborts,
but before that thread can communicate with debuggerd, another thread
calls wtf, which overwrites the abort message from the original
failing thread.
Fix this by changing this to an error level log message.
Bug: 21490722
(cherry picked from commit 2d073ba83c570466a7f77d1cd9193ab4a60eaee4)
Change-Id: Ib9daedf114a2e0ecc424641e4929cc4d15b0c776
To address the UX comments, this CL modifies the dialogs when the
device is rebooted to install an update or to perform factory data
reset.
Bug: 20949086
(cherry picked from commit 81dce6631396012e8b722bbed6d003f584800ae1)
Change-Id: I6d0cbbbaf184806366c6581c1c2e7dbcc5d89a17
/system/bin/uncrypt needs to be triggered to prepare the OTA package
before rebooting into the recovery. For larger packages, uncrypt may be
killed before it finishes the work after the timeout. Change to monitor
the uncrypt status and show the progress to user.
Needs matching changes in bootable/recovery/uncrypt, system/core and
external/sepolicy.
Also pick up the two NPE fixes in commits
9bb765448df43d41e0a3edb7de1d1641c9251c35 and
da3f63ffb87397943546a7c5c893ce98f2489df2.
Bug: 20012567
Bug: 20949086
(cherry picked from commit 90237f7beb55dae79cdcba5271f96be778573737)
Change-Id: Ibf2fc80032967e5f6cda3cd469005dd29665c87c
glFinish() dequeues a native buffer, and it fails when
the bufeer has been abandoned, this is ok and will not
casue the app crash
GL_OUT_OF_MEMORY is generated in this case, and it is
not reset until glGetError called. This is happened in
build layer function, glGetError is called after glTexImg2d,
and get GL_OUT_OF_MEMORY, then this function return as OOM,
and app crash
Fix it by adding a glGetError after glFinish
Change-Id: I8803a726b6f609c4a2f8a6aa6bb7ff7064808932
Custom parser can handle nested ICU messages even if they
are split into multiple fragments. Code reworked to encapsulate
all pseudolocalization logic in Pseudolocalizer and PseudoMethods
classes. To minimize a changelist size, some static functions
remained. Fake BiDi pseudolocalization method is reimplemented
to handle word boundaries correctly. Unit tests added.
Change-Id: I9fb4baf4e3123df5dd6d182cca02bb7b0489ca71
b/21187932
Dependency from one kernel to another kernel -- where one reads the
other's output to a global allocation -- was not handled correctly.
This CL fixed that. Needed to make a new CTS test pass.
Change-Id: I500f9cac9d89bcaec7c186e942ba4a7d413daadb
(cherry picked from commit 85858718c0fc8f4f17ee18e5d62ec0614a8bc780)
Modified UTF-8 and UTF-8 differ with respect to how they handle
non-BMP characters. Modified UTF-8 uses 2 x 3 byte encodings, one
each for the high and low surrogate, whereas UTF-8 uses a single
4 byte sequence.
File systems don't specify and encoding and therefore the file name
encoding will vary depending on how it's created. All standard
Java APIs (java.io.File / FileOutputStream etc.) use Modified UTF-8
filenames, so we assume that's the status quo.
We will also audit code from the rest of the platform to make sure
that file names are encoded consistently.
bug: 21578056
Change-Id: I8e37af7f7cc442805a48899917f8e61c8f81fba6
If there is an Activity Z of Task T needs be visible but
isn't running, and the process P of Z is existed, it will
just to schedule launch Z.
The problem will happen when P is died (e.g. kill itself)
right before scheduleLaunchActivity. Once RemoteException
is caught, startSpecificActivityLocked will try to restart
the process and run cleanup procedure because the process
record is existed (death recipient of P has not entered AMS
yet). And assume task T contains X, Y, Z. X and Y have
declared stateNotNeeded=true, so X and Y will be removed
from task T.
Now the size of task T changes from 3 to 1. And because
activityNdx=2 when updating Z, the next round (--activityNdx)
will have exception at activities.get(activityNdx):
IndexOutOfBoundsException: Invalid index 1, size is 1
The ActivityRecord in TaskRecord is removed by below flow:
ActivityStack.ensureActivitiesVisibleLocked
ActivityStackSupervisor.startSpecificActivityLocked
ActivityStackSupervisor.realStartActivityLocked
ApplicationThreadProxy.scheduleLaunchActivity -> IPC fail
ActivityManagerService.startProcessLocked
ActivityManagerService.handleAppDiedLocked
ActivityStackSupervisor.handleAppDiedLocked
ActivityStack.handleAppDiedLocked
ActivityStack.removeHistoryRecordsForAppLocked
ActivityStack.removeActivityFromHistoryLocked
task.removeActivity(r) -> mActivities.remove(r)
There is also similar patch to solve the same problem:
https://android-review.googlesource.com/143780/
Change-Id: Iac646bcb8ed3d3cfb2bda14e05e11abfcfe980d1