Commit Graph

175157 Commits

Author SHA1 Message Date
Elliott Hughes
c64df290e4 Android always has <malloc.h>.
Change-Id: I9e18daeec26380c439f823e6a55ee61773c1b680
2015-07-07 19:19:34 -07:00
Neil Fuller
50d11ded0d Merge "Reimplement LocalSocket methods using android.system.Os" 2015-07-07 16:11:48 +00:00
Elliott Hughes
0254af6f68 Merge "Fix "Bluetooh" logging typo." 2015-07-07 06:00:56 +00:00
Elliott Hughes
7271613ed6 Fix "Bluetooh" logging typo.
Change-Id: I2b9aea64f1b53e100ead6e71835bf5935b410eb9
2015-07-06 22:10:36 -07:00
Mike Lockwood
593dfbb291 Merge "Miss USB device Interface from UsbManager.getDeviceList()." 2015-07-06 17:10:31 +00:00
wang.zhenyu
19b26f8754 Miss USB device Interface from UsbManager.getDeviceList().
In the scenario that you connect more than one device to android phone with an usb hub,
when you attach the second device,mNewConfigurationis is still corresponded to the first
device unless another mNewConfiguration is created by a new operation.
However,before another mNewConfiguration is created,setInterfaces() in addUsbConfiguration()
has already been executed. Problem is that mNewInterfaces has already been cleared when
it finished endUsbDeviceAdded for the first device. As a result,the UsbInterface descriptor
in the first device's Configuration descriptor is set to null.

Change-Id: I0ba4f07c809d07ebebed633e43c3ee8e2e4c5060
2015-07-06 11:35:44 +08:00
Neil Fuller
d2df87eb44 Reimplement LocalSocket methods using android.system.Os
InputStream.available()
OutputStream.flush()

Bug: 3106438
Change-Id: I3a9425c323229e27bb72f6232dd13f7579586840
2015-07-03 15:16:37 +01:00
Neil Fuller
761e39e189 Merge "Switch to using android.system.Os for more calls" 2015-07-03 14:07:34 +00:00
Neil Fuller
c80af6d84d Switch to using android.system.Os for more calls
The methods being switched here should involve no important
semantic changes. socket.getSoTimeout() is now implemented:
previously it would have returned 0 in all cases.

Some tidy up of unimplemented / commented code.

Switching other calls to use Os would carry more risk and
will be handled separately they can be switched safely.

Bug: 3106438
Change-Id: I5526249395565fee6e43f159a2b5975b0d41d058
2015-07-03 13:02:08 +01:00
Narayan Kamath
6bcdf90e49 Merge "Delete unused testing scripts and WithFramework." 2015-07-02 11:18:19 +00:00
Narayan Kamath
c21dab9dcb Delete unused testing scripts and WithFramework.
These scripts haven't worked in a long time now. run_core_test
uses VM options that aren't supported and WithFramework (which is
unmaintained) and run_junit.sh refers to an APK that doesn't
exist anymore.

If anyone wishes to run these tests individually, they can just
use vogar instead :
$ make vogar vogar.jar
$ vogar --mode=activity frameworks/base/tests/CoreTests/android/core/Sha1Test.java

This also allows us to delete the WithFramework class, which was
only referenced by these obsolete scripts.

bug: 22078684
Change-Id: I481f6721d51d50456421a1526c370b93aec9b351
2015-07-02 11:41:52 +01:00
Narayan Kamath
1d50879b1d Merge "Remove memory leak in PersistentDataBlockService jni" 2015-07-01 13:32:04 +00:00
Henrik Baard
c90ca48a7c Remove memory leak in PersistentDataBlockService jni
When calling the methods
 com_android_server_PersistentDataBlockService_getBlockDeviceSize()
 com_android_server_PersistentDataBlockService_wipe()
memory is leaked because string created by
 GetStringUTFChars() is not released.

Use ScopedUtfChars instead to ensure that memory is released.

Change-Id: I880a6d66a4824778b411b858774b8ffa009c1e17
2015-07-01 13:30:26 +00:00
Miao Wang
3b43f862d0 Merge "[RenderScript] update the type of offsets for BLAS.BNNM" 2015-07-01 05:53:42 +00:00
Miao Wang
2514806817 [RenderScript] update the type of offsets for BLAS.BNNM
bug: 22184114

Change-Id: I7e7132aa3563f32de32640567b381f8f5bddf491
(cherry picked from commit 6099ee6e08)
2015-06-30 22:29:47 -07:00
John Hoford
6463dd5247 Merge "add comment about xor not being porter/duff Bug: 21934855" 2015-06-30 22:34:44 +00:00
John Hoford
6ba4cb7773 add comment about xor not being porter/duff
Bug: 21934855

Change-Id: I99394bd8a7a40a220c05118564b532f2533da38a
2015-06-30 19:53:41 +00:00
Stephen Hines
61e8329bb8 Merge "Replace parentheses with curly braces to fix vector doc bug." 2015-06-30 01:11:15 +00:00
Stephen Hines
6c304d36b9 Replace parentheses with curly braces to fix vector doc bug.
https://code.google.com/p/android/issues/detail?id=178299

Change-Id: I3ae31d48a39e8db9976fdedde560e870b23e2c83
2015-06-29 18:06:10 -07:00
Yang Ni
0eba40194e Merge "Add Java doc comments on script group name reuse" 2015-06-29 22:39:50 +00:00
Yang Ni
3020953243 Add Java doc comments on script group name reuse
b/21999787

Change-Id: Id9a7bad4ce91f3afdd82a1288cf94430f3aef9bb
(cherry picked from commit dbb6fd58a4)
2015-06-29 15:38:25 -07:00
Yusuke Sato
16d520fce6 Merge "Rename ZipEntryName to ZipString" 2015-06-29 17:49:33 +00:00
Wale Ogunwale
ffe72f70e0 Merge "Use the correct lock to protect members in PolicyControl" 2015-06-29 15:09:30 +00:00
tiger_huang
e8befb3531 Use the correct lock to protect members in PolicyControl
Members in PolicyControl can be accessed by multiple threads via the
public functions called by PhoneWindowManager. Most of the functions
are called with the window-manager-lock held, but reloadFromSetting()
is an exception.

In this patch, we acquire the window-manager-lock before calling
reloadFromSetting() to ensure accessing the members with the same
lock held.

Change-Id: I54ac5cab2a2d74c568fa96145f7a6741c6d99e36
2015-06-29 09:22:01 +00:00
Yusuke Sato
f162faaa12 Rename ZipEntryName to ZipString
Also add a 4th parameter to StartIteration(). This is for
https://android-review.googlesource.com/#/c/156771/.

Bug: 21957428
Change-Id: Ifbf9aec2f04b214b57e99c306282d7c0d39675a9
2015-06-25 14:58:16 -07:00
Tenghui Zhu
78db19c25a Merge "Limit dotProduct value to 1.0f, so acosf would not return NaN." 2015-06-25 21:07:14 +00:00
Lazar Trsic
b561f39d01 Limit dotProduct value to 1.0f, so acosf would not return NaN.
Due to precision loss of float math, we sometimes get 1.000001f for
dotProduct. This causes NaN result from acosf() and floor() funcs.

At the moment, this does not cause any problems on ARM, as casting
NaN to int results in 0. On mips however (possibly on x86), such cast
gives INT_MAX, so crash occurs when trying to use the resulting value.

Change-Id: I8e0285a0306a65b8469d9f4885c19665066fc4c8
2015-06-25 11:11:55 +02:00
Narayan Kamath
fdb70dc434 Merge "Fix filedescriptor leakage in MediaMetadataRetriever" 2015-06-25 08:33:50 +00:00
harvey_tsai
e1856e4829 Fix filedescriptor leakage in MediaMetadataRetriever
setDataSource(String) throws an IllegalArgumentException
when an IOException or FileNotFoundException occurs, but doesn't
close FileDescriptor accordingly.

Change-Id: Ib6e0f1418afeeb19e03abd4bedb4cc845a58b6b4
2015-06-25 09:31:18 +01:00
Narayan Kamath
a78c0e0b9a Merge "Fixed Javadoc typos" 2015-06-25 08:27:47 +00:00
Philipp Hasper
802aa0f8a2 Fixed Javadoc typos
Simple single character typos

Change-Id: I17660dbb3b7ee6597637e8d76770f434ebf202ea
2015-06-25 08:09:43 +00:00
Andreas Gampe
08592bd0f7 Merge "Frameworks/base: Add tracing system properties" 2015-06-25 03:44:45 +00:00
Andreas Gampe
cadcd51e05 Frameworks/base: Add tracing system properties
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 98f406f6f3)

Change-Id: I3785cc5715acadbee81ef7b45081ed780f1351d3
2015-06-24 18:44:05 -07:00
Alan Viverette
c2a3071379 Merge "Duplicate description on AccessibilityEvent" 2015-06-24 22:47:03 +00:00
Mathieu Chartier
9a65f9ddd0 Merge "Add an AM option to start with allocation tracking" 2015-06-24 20:55:38 +00:00
Man Cao
cfa78b2080 Add an AM option to start with allocation tracking
The new option "--track-allocation" is to work with the new
allocation tracker in ART.

Bug:20037135
Change-Id: Ic5f8945ab4c1f167c27b05ad0d11d04bac680c1f
2015-06-24 13:29:29 -07:00
Hiroshi Yamauchi
299a339335 Merge "Clarify art.gc.gc-count-rate-histogram runtime stat." 2015-06-24 18:13:00 +00:00
Hiroshi Yamauchi
169bca74e9 Clarify art.gc.gc-count-rate-histogram runtime stat.
(cherry pick commit 2d6327d0ad)

Bug: 21491908
Change-Id: I84d93aa73eebc327513c4663a6b606e2dad9a0b7
2015-06-23 13:28:25 -07:00
Wale Ogunwale
e6734b6b12 Merge "Fix javadoc for Adapter.getViewTypeCount()" 2015-06-23 17:03:51 +00:00
Minhyeok Jeong
ab1c9e0774 Fix javadoc for Adapter.getViewTypeCount()
Remove duplicate words.

Change-Id: Iaeeb8f74313d2ca88c28e4b3672316367b16ca2d
2015-06-21 04:51:22 +09:00
Wale Ogunwale
5acb30de6f Merge "Apply the scale to surfaceinsets when computing crop region" 2015-06-19 20:34:47 +00:00
Nick Kralevich
1c7f0860c7 Merge "overlaytests: fix testrunner.py md5sum invocation" 2015-06-19 19:34:29 +00:00
Stephen Smalley
415fa1f5c0 overlaytests: fix testrunner.py md5sum invocation
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>
2015-06-19 14:37:58 -04:00
seunghyun85.lee
92d9c81835 Apply the scale to surfaceinsets when computing crop region
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>
2015-06-19 07:56:31 -07:00
Wale Ogunwale
ce7dba6bdf Merge "[ActivityManager] Fix index OOB when updating visible." 2015-06-18 14:38:20 +00:00
Narayan Kamath
b77bc86924 Merge "Delete android.speech.srec.*" 2015-06-17 13:15:03 +00:00
Narayan Kamath
3cd78b4fa3 Delete android.speech.srec.*
This code had an undeclared dependency on libsrec_jni which
we no longer build.

bug: 21855957

(cherry picked from commit b39dfe87b8)

Change-Id: I6c97f22916766714ae899cf51f1b56cde308af8e
2015-06-17 14:14:23 +01:00
Narayan Kamath
a01d46963a Merge "ZipFileRO: Use precise widths for zip file types." 2015-06-17 13:13:26 +00:00
Narayan Kamath
407753c456 ZipFileRO: Use precise widths for zip file types.
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 4600dd053d)

Change-Id: I7886cb37a229cc27c625699c80e6a6a6117d2203
2015-06-17 13:13:16 +00:00
Vladimir Marko
dc22cfed5d Merge "Don't prevent notification updates in DOS protection." 2015-06-17 09:04:35 +00:00