The title of the Phone options dialog is displayed using wrong
translation if the user changes the current language setting. Moving
the setTitle call to prepareDialog to ensure that the title gets
updated before the dialog is shown.
Change-Id: I03ff59c7f4ff711a06b05de7cca94fa928cf67ef
The finalize() call did not clean up completely, this eventually
caused the android.process.acore to crash since it ran out of fds
and GREF to increased above 2000 if an application forgot to close
its cursor objects. A warning was also added when this happens so
that application developers can correct their mistake. The
included test case tries to verify that the finalizer works as
expected by creating a bunch of Cursor objects without closing
them (without this fix the acore process crashes after about 400
iterations and the test case ends with "Process crashed").
Change-Id: I11e485cef1ac02e718b2742108aa88793666c31d
Cyclic references can occur between a Service object held by an
application and a ServiceRecord object held by the system server.
A part of the problem is that binders are leaked and since many binders
are implemented by inner classes of services these services are also leaked.
This causes low memory problems. The solution is: When a Service is beeing
destroyed, go through the ServiceRecord's all IntentBindRecord and set its
binder references to null. This allows the binder and the service object to
be garbage collected.
Change-Id: I5a257521964851f34c08ffb3908feaad96b1bafe
When using sendOrderedBroadcast(..) with a BroadcastReceiver the
BroadcastReceiver instance was not released. The reason for this was that
the resultTo field in the BroadcastRecord kept a reference until it was pushed
out of the mBroadcastHistory. This reference in turn kept a reference to the
process side IIntentReceiver (implemented in ReceiverDispatcher$InnerReceiver).
This in turn had a strong reference (through mStrongRef) to the Context.
In order to keep the debug output the resultTo is also kept as a String in the
new resultToString variable.
Change-Id: I4382a22a541c27b3694fb2b78a04ee820b235f8f
The service connection to the previous live wallpaper is unbound when
a new wallpaper is effective. Although the service connection is
unbound it is not disconnected and its reference to wallpaper's
service and engine is still effective. This adds up to the total
JNI references and causes dalvik (hosting system_server) to abort.
Fix is to release the references in clearWallpaperComponentLocked.
Change-Id: Idd2bab83a56d2e6c6dd7ab9be08d5e14887aa384
ServiceRecord's bindings is a hashmap to keep track of all active
bindings to the service. This is not cleared when the service is
brought down by activity manager. This adds up the references to
IntentBindRecords and its references to ServiceRecord. Fix is to
clear the bindings.
ServiceRecord's restarter is a reference to the service and is not
cleared when the service is brought down by activity manager. This
adds up the references to ServiceRecord. Fix is to set the reference
to null when the service is brought down by activity manager.
Change-Id: Ica448cd5f60192c8adb23209b5d0e2cf0c04e446
If writeString8 is called with the following sequence:
writeString8(String8(""));
writeString8(String8("TempString"));
Then in the readString8, the 2nd String i.e. "TempString" is not read,
instead an empty string is read.
The bug comes because of the write call for String8("") where there are
no String bytes present. In the write Statement, an extra ‘\0’ is
written. During the Marshalling, Following bytes are written:
1 2 3 4 5 ...
0x0 0x0 0xB ‘T’ ‘e’ ...
The readString8 function has a check that, if String length is 0, don’t
read anything. So the first byte is read as the length for the first
string. The second byte i.e. ‘\0’ is read as the length for the second
string and hence the second string becomes empty too.
Change-Id: Id7acc0c80ae16e77be4331f1ddf69ea87e758420
Korean phones write to the ADN record of the SIM in a non-standard way.
When UCS2 is not used, the alphaTag will be written in the KSC5601
encoding. This contribution adds support for reading that format when
a Korean SIM card is used.
Also adds support for KSC5601 in SMS.
Change-Id: I81a4a6949359b4d23a937ac2d813bafed2b85ff6
This fix improves the performance by caching the string that should
be returned, and reuse it next time if possible.
This will make it faster to switch between activities, approximately
half the time to create the new view when changing from landscape to
portrait. Also, the time for starting a new application is be reduced
as WindowState.toString is being called thousands of times in this
case.
Change-Id: I2b8b9bc1e251d1af43b6c85f049c01452f2573a2
The content resolver does not take care of the IllegalStateException
that is thrown in getType and that needs to be fixed.
Change-Id: I3e66f1aa259ab91fb9233e1ba07faa1ab6c3f2dd
Be compatible with the old DownloadProvider behavior of being able to
operate on content URIs returned from .insert()
Bug: 3242328
Change-Id: Ibd2ed553c87ea694d4b09a8265c7131fae588719
- Check for active phone in ICC handler before processing messages.
- Boundary check for gsm/cdma subscription app index
while retrieving the ICC Card App.
Change-Id: I3d54447e8d48e3482763e78eeb2a737a34cec321
Android telephony does not release the partial wakelock right away if
there is an error in sending the RIL request. The wake lock is released
only after EVENT_WAKE_LOCK_TIMEOUT occurs that prevents the phone to go
in power collpase. The change is to release the wake lock as soon as the
error in send is detected.
Also, change RIL#send not not send a request if there is no connection to
vendor RIL, as the request will always fail.
Change-Id: Ia39a4b9ac12f4064e301a65abfd26409d49babe1
To monitor the dropbox an application have to either poll the dropbox
and keep track of all entries or observ the /data/system/dropbox
directory. The later requires that the application runs as system-user.
This commit adds that a broadcast intent is sent when something is written
to the dropbox and an application can just listen on this intent and
then reads the entry with help of the DropboxManager class.
The application have to hold the permission android.permission.READ_LOGS
to get the intent.
Change-Id: I1f77f206a243df69f4ed5306078c47f7bf6181ec
As the Arabic language formatter would make number "1,2,3" to Arabic
language word means one,two,three, NumberPicker won't like to show
any thing other than numbers, add local settings to US, make the
number 1,2,3
Change-Id: If2d161ac4133f6c9c6e1ec284d6d2fbf01855fa0
In bad network conditions and where switches often occur between 2G and
3G the timeout of 20s is too short.
Setting this timeout to 60 seconds will improve functionality in bad conditions
while it will not affect functionality in good networks. This change also aligns
the timeouts with the timeouts used by the Browser (Connection.java).
Change-Id: I0fbe3cbfe734f8d55a41bfa5d8ab6b332a19f912
The strings used by the framework for network initiated position
requests are now string resources that can be properly localized.
Change-Id: If1cba89adb1bfcb9c8fdb59b9c5aa1107b11279e
This patch allows users of WindowManagerService.injectKeyEvent() to
set flags on the key event being injected.
In particular this allows long presses (FLAG_LONG_PRESS) to be
injected into the window manager.