Commit Graph

14418 Commits

Author SHA1 Message Date
The Android Automerger
9660d32e74 merge in mnc-release history after reset to mnc-dev 2015-06-06 01:01:01 -07:00
Yabin Cui
e997e9155e am 61b040a5: resolved conflicts for merge of ea248d9c to lmp-mr1-ub-dev
* commit '61b040a57094093cfb090ebb1c321d4a69c20b64':
  Make sys_resource test more robust.
2015-06-05 02:18:45 +00:00
Dmitriy Ivanov
c534603f8d Hide __atexit
Bug: http://b/21640806
Change-Id: I778b35c8c7538859179e97fcf5a82db2fcd9e50f
(cherry picked from commit 9cf6fc304b)
2015-06-04 14:51:26 -07:00
Christopher Ferris
f2e86cd980 Merge "Reorder DIR structure due to bad apps." into mnc-dev 2015-06-04 20:57:57 +00:00
Christopher Ferris
5edb0f40f6 Reorder DIR structure due to bad apps.
It turns out that apportable apps expect that the DIR structure is
the same as in L and below. Modify the structure to have the same
order, and move the new variable to the end of the structure.

Bug: 21037208
Change-Id: Id1258e9dc19423109a2c3a8086d3022965591166
2015-06-04 13:30:45 -07:00
Dmitriy Ivanov
34de7f8497 Strip version info when extracting symbols
Bug: http://b/20139821
Change-Id: I1c1ed1b97a75936407e996698b98b94a7175ac30
(cherry picked from commit 6cda074289)
2015-06-04 11:15:13 -07:00
The Android Automerger
2ff7422771 merge in mnc-release history after reset to mnc-dev 2015-06-03 01:01:03 -07:00
Dmitriy Ivanov
0c29aabad2 Merge "Backward compatibility for dlsym(RTLD_DEFAULT, ...)" into mnc-dev 2015-06-03 01:09:34 +00:00
Dmitriy Ivanov
04f7e3e955 Backward compatibility for dlsym(RTLD_DEFAULT, ...)
Do not skip RTLD_LOCAL libraries in dlsym(RTLD_DEFAULT, ...)
 if the library is opened by application with target api level <= 22

Bug: http://b/21565766
Bug: http://b/17512583
Change-Id: Ic45ed1e4f53e84cba9d74cab6b0049c0c7aa8423
2015-06-02 18:06:24 -07:00
Yabin Cui
61b040a570 resolved conflicts for merge of ea248d9c to lmp-mr1-ub-dev
Change-Id: I362ab2e25e3368c71cb1af51cee2e8fb5ce53e61
2015-06-02 16:47:42 -07:00
Yabin Cui
ea248d9ca8 Merge "Make sys_resource test more robust." into lollipop-cts-dev
automerge: 492a0bf

* commit '492a0bf212973baa1c33d584d57e75395774447f':
  Make sys_resource test more robust.
2015-06-02 22:03:23 +00:00
Nick Kralevich
f56bad974b Merge "libc: Add O_PATH support for fgetxattr / fsetxattr" into mnc-dev 2015-06-02 22:02:43 +00:00
Yabin Cui
492a0bf212 Merge "Make sys_resource test more robust." into lollipop-cts-dev 2015-06-02 22:02:29 +00:00
Yabin Cui
e7ece90b50 Make sys_resource test more robust.
Bug: 19482626

"ulimit -c xxx" command may run before bionic-unit-tests.
Make sure sys_resource test fails gently in that case.

Change-Id: Ic3b5ed8b20acba56df8c5ef082c88e5050e761aa
(cherry picked from commit 4853f40f3f)
2015-06-02 14:40:26 -07:00
Dmitriy Ivanov
38c37d6705 Work around for libraries without dt_soname
Applies only for apps targeting sdk version <= 22

Bug: http://b/21565766
Change-Id: If0bf2229dc1341e9ca09f9a05d0890515273d5a2
2015-06-02 13:45:15 -07:00
Nick Kralevich
c92f9f8069 libc: Add O_PATH support for fgetxattr / fsetxattr
Support O_PATH file descriptors when handling fgetxattr and fsetxattr.
This avoids requiring file read access to pull extended attributes.

This is needed to support O_PATH file descriptors when calling
SELinux's fgetfilecon() call. In particular, this allows the querying
and setting of SELinux file context by using something like the following
code:

  int dirfd = open("/path/to/dir", O_DIRECTORY);
  int fd = openat(dirfd, "file", O_PATH | O_NOFOLLOW);
  char *context;
  fgetfilecon(fd, &context);

This change was motivated by a comment in
https://android-review.googlesource.com/#/c/152680/1/toys/posix/ls.c

(cherrypicked from commit 2825f10b7f)

Change-Id: Ic0cdf9f9dd0e35a63b44a4c4a08400020041eddf
2015-06-02 10:08:05 -07:00
The Android Automerger
3619d6b922 merge in mnc-release history after reset to mnc-dev 2015-06-02 01:00:48 -07:00
Dmitriy Ivanov
c4ebe60e1a Fix dlsym(handle_of_main_executable, ...)
According to man dlopen(3) and posix docs in the case when si is handle
  of the main executable we need to search not only in the executable and its
  dependencies but also in all libraries loaded with RTLD_GLOBAL.

  see also: http://pubs.opengroup.org/onlinepubs/9699919799/functions/dlopen.html

Bug: http://b/21528224
Bug: http://b/17512583
Bug: https://code.google.com/p/android/issues/detail?id=173822
Change-Id: Ib2801367ba48b6f3704da89a6d9f5e6911430013
(cherry picked from commit f439b5a318)
2015-06-01 16:57:33 -07:00
Dan Albert
c5e02eeb35 Cleanup ftruncate negative test.
Addresses post-submit comments from
I54692ab8105dd09db6af7a2c0894a17bdd118aa0.

Bug: http://b/21309901
Change-Id: Ie19ee8cdcc4055a65fe7dfc103156e54eafe8977
(cherry picked from commit 9d476a02e9)
2015-06-01 13:24:36 -07:00
Dan Albert
5f3e19dbbe Fix error handling for negative size in ftruncate.
Bug: 21309901
Change-Id: I54692ab8105dd09db6af7a2c0894a17bdd118aa0
(cherry picked from commit c05554ec5c)
2015-06-01 11:28:13 -07:00
The Android Automerger
2783166c35 merge in mnc-release history after reset to mnc-dev 2015-05-30 01:01:05 -07:00
Dmitriy Ivanov
c3351ea94d Work around incorrect dt_needed entries
This applies for apps targeting sdk<=22 and
  only for lp32 platforms.

Bug: http://b/21364029
Change-Id: I903e81c9ccda2a8beaba1d132d68c77d30a4cdb2
(cherry picked from commit d974e88046)
2015-05-28 17:42:27 -07:00
Dmitriy Ivanov
ca10ac6dd4 Improve some of error/warning messages
Bug: http://b/20464031
Change-Id: I948141c46f9e054fc45f5934153dee56ce3cd558
(cherry picked from commit 087005f37e)
2015-05-28 15:28:41 -07:00
Dmitriy Ivanov
4a7c3af054 Work around incorrect dt_needed entries
This applies for apps targeting sdk<=22 and
  only for lp32 platforms.

Bug: http://b/21364029
Change-Id: I903e81c9ccda2a8beaba1d132d68c77d30a4cdb2
(cherry picked from commit d974e88046)
2015-05-28 15:25:55 -07:00
The Android Automerger
730c0a475c merge in mnc-release history after reset to mnc-dev 2015-05-28 01:00:47 -07:00
Dmitriy Ivanov
d8ead18145 Add functions to provide target sdk version
Bug: http://b/21364029
Change-Id: I8648d1bff6c8fd6e7cd12da7f128e048b9f2829a
(cherry picked from commit 79fd668bb4)
2015-05-27 16:20:16 -07:00
The Android Automerger
c8e23a4c1a merge in mnc-release history after reset to mnc-dev 2015-05-23 01:00:56 -07:00
Dmitriy Ivanov
15309fde91 Fix RTLD_NEXT lookup for the local_group
Linker used to skip RTLD_NEXT within local_group when
  caller->next is nullptr (which represents load order
  but not the order within local_group dependency tree)

Bug: http://b/21380474
Change-Id: I178fc4657b19bceb871635b177c1df67855b1708
(cherry picked from commit b96ac41b32)
2015-05-22 15:24:13 -07:00
The Android Automerger
4d49212a5f merge in mnc-release history after reset to mnc-dev 2015-05-21 01:00:54 -07:00
Yabin Cui
c15a935202 am fd20a8c2: resolved conflicts for merge of 473d96c0 to lmp-mr1-ub-dev
* commit 'fd20a8c2d669b3f2d63e2d33a32b90d1b7f17b82':
  Fix timer flaky test in lollipop-mr1-cts-dev.
2015-05-20 21:48:09 +00:00
Yabin Cui
fd20a8c2d6 resolved conflicts for merge of 473d96c0 to lmp-mr1-ub-dev
Change-Id: I48269218b152054d527d9257d40490b54205140f
2015-05-20 13:36:56 -07:00
The Android Automerger
aa3ef00a43 merge in mnc-release history after reset to mnc-dev 2015-05-19 01:01:19 -07:00
Yabin Cui
7490c5c594 Hide rt_sigqueueinfo.
Bug: 19358804
Change-Id: I38a53ad64c81d0eefdd1d24599e769fd8a477a56
(cherry picked from commit 40a8f214a5)
2015-05-18 13:34:51 -07:00
Yabin Cui
2b5c2285c0 Remove pthread_detach_no_leak test.
This test has lost its purpose as we are using mmap/munmap for pthread_internal_t. And it is a flaky test.

Bug: 21205574
Bug: 20860440
Change-Id: I7cbb6bc3fd8a2ca430415beab5ee27a856ce4ea7
(cherry picked from commit 2957cc5f10)
2015-05-18 10:31:20 -07:00
The Android Automerger
304307243f merge in mnc-release history after reset to mnc-dev 2015-05-17 01:00:23 -07:00
Dmitriy Ivanov
8557eeb0ad Merge "Apply work around b/19059885 to x86" into mnc-dev 2015-05-16 16:57:16 +00:00
The Android Automerger
51d3926d8a merge in mnc-release history after reset to mnc-dev 2015-05-16 01:00:43 -07:00
Dmitriy Ivanov
69a5fb951d Apply work around b/19059885 to x86
Bug: http://b/19059885
Bug: http://b/21203348
Change-Id: Ic375e9f877d68de8f866d17362879a7dde638465
2015-05-15 18:39:16 -07:00
Chih-Hung Hsieh
43850d19f4 Use unified syntax to compile with both llvm and gcc.
All arch-arm and arch-arm64 .S files were compiled
by gcc with and without this patch. The output object files
were identical. When compiled with llvm and this patch,
the output files were also identical to gcc's output.

BUG: 18061004
Change-Id: I458914d512ddf5496e4eb3d288bf032cd526d32b
(cherry picked from commit 33f33515b5)
2015-05-15 16:29:10 -07:00
Chih-Hung Hsieh
22c21c6b4e Fix opcode to compile with both gcc and llvm.
BUG: 17302991

Change-Id: I31febd9ad24312388068803ce247b295bd73b607
(cherry picked from commit 0a93df369c)
2015-05-15 16:28:38 -07:00
Elliott Hughes
fa7ba6227f Don't use TEMP_FAILURE_RETRY on close in bionic.
Bug: http://b/20501816
Change-Id: Id64b5109cc2b165fa0351b6edbb865a5e5058008
(cherry picked from commit 4e8ef698d0)
2015-05-15 16:24:33 -07:00
John Reck
4cb434df9b Fix regression in crash reporting
Bug: 19532651

Partial revert of be0e43b776

Change-Id: I99e220328aff985facb920ebcd84ac1a016759b5
2015-05-15 15:12:36 -07:00
Dmitriy Ivanov
ff407803db Remove -z global workaround for target x86
Change-Id: I08e75a1c7437c97e4af59316d2c14c7fa3f65e03
(cherry picked from commit 933332462d)
2015-05-15 10:30:47 -07:00
John Reck
d7ad443cfd Fix regression in crash reporting
Bug: 19532651

Partial revert of be0e43b776

Change-Id: I99e220328aff985facb920ebcd84ac1a016759b5
2015-05-15 07:48:33 -07:00
Spencer Low
2a44cfbd7d ScopedFd: Don't use TEMP_FAILURE_RETRY() with close()
According to the comments in Posix_close(), TEMP_FAILURE_RETRY() should
not be used with close():

462bdac45c%5E%21/#F12

Kill ScopedFd by simplifying the single caller.

Bug: http://b/20501816
Change-Id: I248c40b8c2fc95f1938a6edfc245c81847fc44af
Signed-off-by: Spencer Low <CompareAndSwap@gmail.com>
(cherry picked from commit 0346ad7a4f)
2015-05-13 17:47:08 -07:00
Dmitriy Ivanov
4bac6ea463 Improved dlsym tests and fixes to linker
Answers the question: what if dependent library
 was preloaded with RTLD_LOCAL flag.

 Also add test for RTLD_NEXT within local_group.

Bug: http://b/17512583
Change-Id: I79e081e68b3a8c0ed8980d4275a06515fea94ec9
(cherry picked from commit 697bd9fd38)
2015-05-12 13:49:13 -07:00
Elliott Hughes
9cde1dc007 Update NOTICE files (the second time today).
Change-Id: Ifb031d29ee697ee0682bd651e0081493e8016e67
(cherry picked from commit f58ac87182)
2015-05-12 10:52:52 -07:00
Elliott Hughes
dd57029ed1 Simplify three copyright headers.
There's no reason to have multiple years in our own copyright headers,
and given the stupidity of our NOTICE file generation, it just creates
more junk.

Change-Id: I065a3811c2e2584e3b649a18ad9460286bc72b92
(cherry picked from commit c69ace87ec)
2015-05-12 10:34:22 -07:00
Elliott Hughes
97139e6adc Merge "Update NOTICE files." into mnc-dev 2015-05-12 17:29:25 +00:00
Elliott Hughes
f0bd92db89 Update NOTICE files.
Change-Id: I4e170118abf452dd87ffe79d343ba1e2b53955de
2015-05-12 10:09:01 -07:00