214774 Commits

Author SHA1 Message Date
Chad Brubaker
5b63231a31 Merge "Add stub isCTVerificationRequired methods" 2016-08-09 19:13:01 +00:00
Yi Kong
67aaa079ee Merge "Track libcore change ee24b6322448ac919231a668e308ebd719aa52d7" 2016-08-09 17:59:07 +00:00
Yi Kong
f646aa14cd Track libcore change ee24b6322448ac919231a668e308ebd719aa52d7
Change-Id: I73dd6af604304ea4eb8e01990454f491af659602
2016-08-09 16:43:32 +00:00
Neil Fuller
294ab080f4 Merge "Tidy up MockWebServer usage" 2016-08-09 16:05:38 +00:00
Neil Fuller
d0c0c8dcab Merge "Add a finalize() method to StrictJarFile" 2016-08-09 10:43:18 +00:00
Tobias Thierer
f61a449ee9 Merge "Ensure apps cannot prevent uncaught exceptions being logged." 2016-08-09 08:55:35 +00:00
Treehugger Robot
78a72f0698 Merge "fix safeMode status in AppWidgetService" 2016-08-08 21:36:46 +00:00
Tobias Thierer
addbf9015a Ensure apps cannot prevent uncaught exceptions being logged.
Let RuntimeInit use an UncaughtExceptionPreHandler to log an exception
rather than relying on UncaughtHandler, which apps can replace. This
makes it easier to diagnose application death, especially during app
compatibility testing for a new version of Android.

Test: Verified manually, with the help of a small sample app (not
checked in), that stacktraces for RuntimeExceptions thrown on main
or background threads are logged even when the app set a default
UncaughtExceptionHandler that swallows the exception with no action.

Note that such an inappropriate UncaughtExceptionHandler will still
cause threads to die without the app being killed, which it should be.
In an exception then happens on the main thread, the app will freeze
until the ANR dialog kicks in after a few seconds. I have manually
verified that this behavior is unchanged from before this CL.

No new integration tests are included because the default system
behavior has not changed.

Bug: 29624607
Change-Id: Ie87377b0bcadc3ba4083a8ab1bedb8f3dd95a4bd
2016-08-08 17:59:28 +01:00
Treehugger Robot
3f67a1855e Merge "Fix random crash in libhwui" 2016-08-05 18:23:14 +00:00
Tobias Thierer
e49469aed1 Merge "APIs for ProcessBuilder.Redirect" 2016-08-05 12:36:35 +00:00
Przemyslaw Szczepaniak
50f3429d14 Merge "Track libcore change 0e393b4d628541e84e31210342f4103315c07e23" 2016-08-05 09:36:41 +00:00
Hans Boehm
497ac5eccb Merge "Update SMP documentation." 2016-08-05 01:59:38 +00:00
Hans Boehm
9e629adc4a Update SMP documentation.
The old version was seriously obsolete, primarily in that it ignored
C11 and C++11 atomics and the programming model underlying them.  As
a result it paid way too much attention to hardware characteristics,
which 0.001% of application programmers should really be aware of.
And some of those hardware descriptions were also obsolete.

This is a fairly complete rewrite.

Bug: 18523857

Change-Id: Icc14a390f74486193486c2ba07a86b05611e7d3c
2016-08-04 14:21:48 -07:00
Andre Eisenbach
5cfe8a8315 Merge "Fix bad index usage" 2016-08-04 20:20:02 +00:00
Jakub Pawlowski
d167db19a9 Fix bad index usage
Bug: 27999121
Change-Id: Ie2ba6f71bbf6f789a3c1016ba2f0051b809ac87e
2016-08-04 20:19:52 +00:00
Chih-hung Hsieh
a11a8e5086 Merge "Enable clang for arm64." 2016-08-04 17:13:53 +00:00
Chih-Hung Hsieh
248bed0334 Enable clang for arm64.
emutls should work now with latest prebuilt clang/llvm.

BUG: 25642296
Test: build and boot up on arm64 emulator.

Change-Id: I5c8dd36a1575436e5fd56e91f7c285f2b3e6546f
(cherry picked from commit 8ffb6b76f7a72e14882e09f882494e5f7d5fc45d)
2016-08-04 17:09:55 +00:00
Tobias Thierer
f1d119ccd3 Merge "Add API for setsockoptInt(fd, IPPROTO_TCP, TCP_USER_TIMEOUT, value)" 2016-08-04 10:51:14 +00:00
Andre Eisenbach
f28f6bb2b0 Merge "HFP 1.7 profile update (3/4)" 2016-08-04 01:06:47 +00:00
Mudumba Ananth
709b11ef7a HFP 1.7 profile update (3/4)
-> Android Framework changes to add support for
   an API to send indicator change in AG.
-> Added a system intent for broadcasting assigned number(ID)
   of the supported HF indicators and their values (if received)

Bug: 19983867
Change-Id: If26a7ae5da5686da72ebca9ec3decfe086e2ffb6
(cherry picked from commit 0d98ebf997b24e96d0328b4195a22832f9ae2664)
2016-08-03 17:55:04 -07:00
Treehugger Robot
b7eb1d7eaf Merge "Remove write type from GATT descriptor writes (1/4)" 2016-08-03 23:54:35 +00:00
Jakub Pawlowski
8e970d6ab4 Remove write type from GATT descriptor writes (1/4)
According to the Bluetooth Core specification v4.2, Vol 3, Part G,
section 4.12.3: "The Attribute Protocol WRITE REQUEST is used
for this sub-procedure".

Change-Id: I141dd24ed5911d5d485b52a1b661835b9960921a
2016-08-03 10:42:47 -07:00
Tobias Thierer
4122b913f3 Add API for setsockoptInt(fd, IPPROTO_TCP, TCP_USER_TIMEOUT, value)
Test: "make" succeeds.

Bug: 30402085
Change-Id: I4bc4b5dcfab04ac756578c2fae7a337e74587b66
2016-08-03 18:16:14 +01:00
Tobias Thierer
258a554f62 Merge "Stop profiling on uncaught exception." 2016-08-03 10:42:37 +00:00
Jakub Pawlowski
d13954e8c6 Merge "GATT Server refactoring (2/4)" 2016-08-03 10:21:44 +00:00
Tobias Thierer
b68106cf2a Merge "Fixes the system server crash issue caused by uncatched exception." 2016-08-03 09:54:53 +00:00
Tobias Thierer
554284edf3 Merge "remove x attribute of java file" 2016-08-03 09:54:24 +00:00
Treehugger Robot
1085be0ce3 Merge "Zygote: Add CAP_WAKE_ALARM to system_server to properly support timerfd alarms" 2016-08-03 00:04:19 +00:00
Jakub Pawlowski
d75f512aa2 GATT Server refactoring (2/4)
Bug: 27999121
Change-Id: Ia5f91298a4b01b62adebc8adc30f27f757259588
2016-08-02 20:45:06 +00:00
Ganesh Mahendran
7f7df65475 remove x attribute of java file
java file do not need x attribute, so this patch
removes it.

Change-Id: I807722ac3f40688f032228294d61a4266d0e9e60
Signed-off-by: Ganesh Mahendran <opensource.ganesh@gmail.com>
2016-08-02 19:33:26 +00:00
Tobias Thierer
8ad86a3d1a Stop profiling on uncaught exception.
When "handling" an uncaught exception, make an attempt to stop
profiling. In case profiling was active, this will avoid losing
the profiling buffer.

This change is required as a base in order for
https://android-review.googlesource.com/#/c/249721/
to merge cleanly.

(Cherry picked from commit 4c79fea9efea7cfa739cf5b5f525ddadb28e52a6)
Bug: 26291225
Change-Id: I35f352e5f28eafe4702da9eae587c3b65c360b3a
2016-08-02 17:32:39 +01:00
Chad Brubaker
bd62098a54 Add stub isCTVerificationRequired methods
Bug: 28746284
Change-Id: Iebeecba7356ac57fedb06d71de63aa9900f2ccd8
2016-08-02 07:57:16 -07:00
Przemyslaw Szczepaniak
bc7820ec76 Track libcore change 0e393b4d628541e84e31210342f4103315c07e23
Bug: 28666126
Change-Id: Ib63e14c5c72fd3a13f09a90358cb137e318a3653
2016-08-02 12:01:07 +00:00
songjinshi
c5e249b9e0 Fixes the system server crash issue caused by uncatched exception.
The restat method of the StatFs may throw an IllegalArgumentException,
so we must to catch it and throw an IOException for the caller
of the trimToFit(),this fix can improve system stability.

https://code.google.com/p/android/issues/detail?id=218359

Change-Id: I54a2f569eea67d3ab628944e3586ca918ec70283
Signed-off-by: songjinshi <songjinshi@xiaomi.com>
2016-08-02 09:47:09 +08:00
Treehugger Robot
6eb30f2060 Merge "libsigchain: intercept bsd_signal on lp32" 2016-08-01 22:39:16 +00:00
Dimitry Ivanov
4c5281862f libsigchain: intercept bsd_signal on lp32
bsd_signal is a deprecated synonym for the signal. Nevertheless
there are apps and libraries calling this function.

libsigchain needs to intercept these calls and handle them the same
way it handles signal() call.

Bug: http://b/30562229
Test: readelf --dyn-sym app_process32 and check that bsd_signal is exported
      readelf --dyn-sym app_process64 and check that bsd_signal is not exported
Change-Id: Iec584070b42bc7fa43b114c0f884aff2db5a6858
2016-08-01 14:19:26 -07:00
Fyodor Kupolov
3e151273a3 Merge "Fix the API compatibility of "UriMatcher#addURI"" 2016-08-01 17:34:32 +00:00
Hidehiko Tsuchiya
5acd41d155 Fix the API compatibility of "UriMatcher#addURI"
The previous patch (ef23bf19 Allow leading slash in path...) made
a single slash path unmatchable.
To solve it, this patch stops removing a slash character if the path
only has a slash character.
Now, a single slash is a matchable path for a URI without path string.

Bug: 29524484
Change-Id: I90b357aa48be1a3e0cf36e75ed2a9d6532908972
2016-07-30 01:47:50 +00:00
Neil Fuller
b69f61472a Add a finalize() method to StrictJarFile
Bug: 25896372
Test: Booted device, installed CTS apps
Test: run cts --class android.util.cts.StrictJarFileTest
Change-Id: I35e238dadd48d2c4ca53ac37a4c5aacdd471a93a
2016-07-29 14:26:35 +01:00
John Stultz
5733f387be Zygote: Add CAP_WAKE_ALARM to system_server to properly support timerfd alarms
The when the timerfd alarm logic was added to the kernel, an oversight was made
and the interface does not check for the CAP_WAKE_ALARM permissions as required
via other kernel methods to trigger an alarm timer.

In v4.8-rc kernels, the change 2895a5e5b3a ("timerfd: Reject ALARM timerfds
without CAP_WAKE_ALARM") was added by Eric Caruso <ejcaruso@google.com>.

After this change (which may be backported to -stable), the AlarmManager will
fail on the first timerfd_create call, and will not be able to set the time
or handle other necessary functions.

The solution here is to add CAP_WAKE_ALARM to the system_server process.

Change-Id: Ifdb16f3ef42711e553f727165de3922d484b5be4
Signed-off-by: John Stultz <john.stultz@linaro.org>
2016-07-28 12:41:04 -07:00
Sergio Giro
877d6e75e6 Merge "api: destroy() and isDestroyed() methods are now default in Destroyable" 2016-07-27 11:30:55 +00:00
Marco Nelissen
e40ab18590 Merge "Fix memory leak in MediaScannerConnection" 2016-07-26 15:37:32 +00:00
Tobias Thierer
5296a60e27 APIs for ProcessBuilder.Redirect
This CL is required for the following libcore change:
Revert "Hide ProcessBuilder.Redirect and associated APIs."

Test: Checked that 'make' succeeds.

Bug: 27464570
Change-Id: I7719ab495863d3fc8cdd00fbe19ac40a37b5a6f2
2016-07-26 15:30:44 +01:00
Jesse Hall
189bbd9f6d Merge "bootanimation: Call eglReleaseThread in threadLoop" 2016-07-25 03:36:57 +00:00
Chih-hung Hsieh
5152fd909c Merge "Fix google-explicit-constructor warnings in frameworks/base" 2016-07-22 00:55:18 +00:00
Chih-Hung Hsieh
faecb78a6b Fix google-explicit-constructor warnings in frameworks/base
* Add explicit keyword to conversion constructors.
* Add NOLINT to implicit conversion constructors.

Bug: 28341362
Test: build with clang-tidy
Change-Id: Ie4d37072ab57d1662d18db4de1c8577247f43337
2016-07-21 16:24:06 -07:00
David Gross
ed6625d907 Merge "Update RenderScript docs: reduction, other API 23/24 changes, cleanup." 2016-07-21 16:15:37 +00:00
xiaoli.xb.zuo
3579b0e1a7 Fix memory leak in MediaScannerConnection
This patch adds releasing of MediaScannerConnection in ClientProxy
after disconnecting and releasing of ClientProxy and
IMediaScannerService in disconnection sequence in
MediaScannerConnection.

Bug: 30150344

Change-Id: I1e162e4c9a0b7a741ace20480bcf06f3151a93bf
2016-07-21 20:34:09 +09:00
David Gross
05eef3040e Update RenderScript docs: reduction, other API 23/24 changes, cleanup.
Substantive changes:
- Add discussion of reduction kernels.
- Use RS_KERNEL in place of __attribute__((kernel)).
- Discuss "context" special argument.
- Special arguments x, y, z may be of type int.
- Discuss multiple inputs for mapping kernels.
- Mention that script-side global writes are not visible in Java.
- Rewrite part of discussion regarding when to use support library.
- Change minimum device version for support library from Android 2.2 (API level 8)
  to Android 2.3 (API level 9).

Stylistic changes (better conformance with style guide):
- Proper use of <i> (italic) versus <em> (emphasis).
- Proper case for headings.
- Proper pattern for Android version numbers.
- Do not use e.g. or i.e.
- Prefer active rather than passive voice.
- Prefer present rather than future tense.

Miscellaneous minor editorial changes.

Bug: 27299393
Bug: 30000147

Change-Id: Ie0a26152714cf8f619d4914218f7262d675bb25f
2016-07-20 16:04:35 -07:00
Christopher Ferris
c95e7a3014 Merge "Remove dependency on android_alarm.h." 2016-07-20 18:03:48 +00:00