OSDN Git Service

android-x86/external-e2fsprogs.git
7 years agoMerge "include sys/sysmacros.h as needed" am: 105f5ecfd8 am: 9e0e531734
Elliott Hughes [Fri, 19 May 2017 19:54:36 +0000 (19:54 +0000)]
Merge "include sys/sysmacros.h as needed" am: 105f5ecfd8 am: 9e0e531734
am: 01b3b9a574

Change-Id: I0908520a62978609982d096ba0b30a74b589ad18

7 years agoMerge "include sys/sysmacros.h as needed" am: 105f5ecfd8
Elliott Hughes [Fri, 19 May 2017 19:53:06 +0000 (19:53 +0000)]
Merge "include sys/sysmacros.h as needed" am: 105f5ecfd8
am: 9e0e531734

Change-Id: I948773bb1b8c30342f089430b0a9f42c6a002eb0

7 years agoMerge "include sys/sysmacros.h as needed"
Elliott Hughes [Fri, 19 May 2017 19:51:12 +0000 (19:51 +0000)]
Merge "include sys/sysmacros.h as needed"
am: 105f5ecfd8

Change-Id: I6e81118e4cb3c6a34752567d6c036c90820c884d

7 years agoMerge "include sys/sysmacros.h as needed"
Elliott Hughes [Fri, 19 May 2017 19:47:22 +0000 (19:47 +0000)]
Merge "include sys/sysmacros.h as needed"

7 years agoinclude sys/sysmacros.h as needed
Mike Frysinger [Fri, 19 May 2017 17:25:59 +0000 (13:25 -0400)]
include sys/sysmacros.h as needed

The minor/major/makedev macros are not entirely standard.  glibc has had
the definitions in sys/sysmacros.h since the start, and wants to move away
from always defining them implicitly via sys/types.h (as this pollutes the
namespace in violation of POSIX).  Other C libraries have already dropped
them.  Since the configure script already checks for this header, use that
to pull in the header in files that use these macros.

Change-Id: Ib7f441fe168c2ca72a274978fea422a0c3010e4f
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
7 years agoMerge "e2fsdroid: skip setting timestamp if src_dir is null" am: 930bc06448 am: 0b69b...
Jin Qian [Wed, 3 May 2017 23:41:06 +0000 (23:41 +0000)]
Merge "e2fsdroid: skip setting timestamp if src_dir is null" am: 930bc06448 am: 0b69bcaa40
am: d984ad62fc

Change-Id: I4859ca06cbb6930a77d0d4e5f8bd6186116aa628

7 years agoMerge "e2fsdroid: skip setting timestamp if src_dir is null" am: 930bc06448
Jin Qian [Wed, 3 May 2017 23:38:36 +0000 (23:38 +0000)]
Merge "e2fsdroid: skip setting timestamp if src_dir is null" am: 930bc06448
am: 0b69bcaa40

Change-Id: I80400e2b51b0b1f849cf72cb1fb6cfa83fec9ba6

7 years agoMerge "e2fsdroid: skip setting timestamp if src_dir is null"
Jin Qian [Wed, 3 May 2017 23:36:05 +0000 (23:36 +0000)]
Merge "e2fsdroid: skip setting timestamp if src_dir is null"
am: 930bc06448

Change-Id: Ied1e99d9729711e5b27ee690c2fff68243050fa7

7 years agoMerge "e2fsdroid: skip setting timestamp if src_dir is null"
Treehugger Robot [Wed, 3 May 2017 23:26:24 +0000 (23:26 +0000)]
Merge "e2fsdroid: skip setting timestamp if src_dir is null"

7 years agoe2fsdroid: skip setting timestamp if src_dir is null
Jin Qian [Tue, 2 May 2017 20:20:27 +0000 (13:20 -0700)]
e2fsdroid: skip setting timestamp if src_dir is null

fs_mgr formats /data without src_dir.

Test: zero-out first 4096 bytes on /data partition and reboot
Bug: 35219933
Change-Id: I12f1eb1002fd96d18fc7a9ae5a529f673eb57273

7 years agoMerge "e2fsdroid: support multiple selinux file contexts" am: 9b2f003f09 am: 42c649def2
Jin Qian [Wed, 3 May 2017 01:47:28 +0000 (01:47 +0000)]
Merge "e2fsdroid: support multiple selinux file contexts" am: 9b2f003f09 am: 42c649def2
am: f1130df245

Change-Id: I77ec6074e86bd23692571365aafbf8dd9b817e3c

7 years agoMerge "e2fsdroid: support multiple selinux file contexts" am: 9b2f003f09
Jin Qian [Wed, 3 May 2017 01:41:40 +0000 (01:41 +0000)]
Merge "e2fsdroid: support multiple selinux file contexts" am: 9b2f003f09
am: 42c649def2

Change-Id: Ia276f1f7f87037fb4c61b53ba60cb5151fd1cc1d

7 years agoMerge "e2fsdroid: support multiple selinux file contexts"
Jin Qian [Wed, 3 May 2017 01:38:40 +0000 (01:38 +0000)]
Merge "e2fsdroid: support multiple selinux file contexts"
am: 9b2f003f09

Change-Id: Ic6344d8cc308a1ea35b095e5275c394133cd99a4

7 years agoMerge "e2fsdroid: support multiple selinux file contexts"
Treehugger Robot [Wed, 3 May 2017 01:31:26 +0000 (01:31 +0000)]
Merge "e2fsdroid: support multiple selinux file contexts"

7 years agoe2fsdroid: support multiple selinux file contexts
Jin Qian [Fri, 21 Apr 2017 23:29:07 +0000 (16:29 -0700)]
e2fsdroid: support multiple selinux file contexts

Support passing a string of multiple selinux file contexts separated by
comma with -S option.

E.g. e2fsdroid -S ctx1,ctx2 output

Test: make systemimage
Bug: 35219933
Change-Id: Icc0f9d5d6180b5db7d68f7de45a1128f5a20be89

7 years agoe2fsck: update quota when optimizing the extent tree
Theodore Ts'o [Thu, 27 Apr 2017 02:14:28 +0000 (02:14 +0000)]
e2fsck: update quota when optimizing the extent tree
am: 16ffbacc8a

Change-Id: I85cc193d75eb0635372491126d6a2318c1490120

7 years agoe2fsck: update quota when optimizing the extent tree
Theodore Ts'o [Sat, 15 Apr 2017 04:29:46 +0000 (00:29 -0400)]
e2fsck: update quota when optimizing the extent tree

If quota is enabled, optimizing the extent tree wouldn't update the
in-memory quota statistics, so that a subsequent e2fsck run would show
that the quota usage statistics on disk were incorrect.

Google-Bug-Id: 36391645

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
(cherry picked from commit 96c8e668f7c780dccbc12b7ecc4cac9a5db2bc97)

Change-Id: I429a0ac64b1cc9e5a288f61ba3942e391e575013

7 years agoMerge "e2fsck: update quota when optimizing the extent tree" am: 2ed20fdc91 am: 93853...
Keun-young Park [Wed, 26 Apr 2017 23:52:02 +0000 (23:52 +0000)]
Merge "e2fsck: update quota when optimizing the extent tree" am: 2ed20fdc91 am: 93853df15e
am: ebe17556a6

Change-Id: Idbaf9027d343b55c5d39c9e76def82b6b51c2a4f

7 years agoMerge "e2fsck: update quota when optimizing the extent tree" am: 2ed20fdc91
Keun-young Park [Wed, 26 Apr 2017 23:50:01 +0000 (23:50 +0000)]
Merge "e2fsck: update quota when optimizing the extent tree" am: 2ed20fdc91
am: 93853df15e

Change-Id: Iae8a0cd530b63f2865c7a9bc50959dbd695c29f2

7 years agoMerge "e2fsck: update quota when optimizing the extent tree"
Keun-young Park [Wed, 26 Apr 2017 23:46:33 +0000 (23:46 +0000)]
Merge "e2fsck: update quota when optimizing the extent tree"
am: 2ed20fdc91

Change-Id: I8cc31a542e36907d0b5404e3c9975e4203df164e

7 years agoMerge "e2fsck: update quota when optimizing the extent tree"
Keun-young Park [Wed, 26 Apr 2017 23:41:06 +0000 (23:41 +0000)]
Merge "e2fsck: update quota when optimizing the extent tree"

7 years agoe2fsck: update quota when optimizing the extent tree
Theodore Ts'o [Sat, 15 Apr 2017 04:29:46 +0000 (00:29 -0400)]
e2fsck: update quota when optimizing the extent tree

If quota is enabled, optimizing the extent tree wouldn't update the
in-memory quota statistics, so that a subsequent e2fsck run would show
that the quota usage statistics on disk were incorrect.

Google-Bug-Id: 36391645

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
7 years agoMerge "libblkid: fix buffer overflow scanning partition name" am: 0474c47c22 am:...
Jin Qian [Mon, 24 Apr 2017 19:03:50 +0000 (19:03 +0000)]
Merge "libblkid: fix buffer overflow scanning partition name" am: 0474c47c22 am: ff35b76641
am: 82452d8df8

Change-Id: I164931b642abbc79725e780cbd400a6131c4c8cd

7 years agoMerge "libblkid: fix buffer overflow scanning partition name" am: 0474c47c22
Jin Qian [Mon, 24 Apr 2017 18:51:19 +0000 (18:51 +0000)]
Merge "libblkid: fix buffer overflow scanning partition name" am: 0474c47c22
am: ff35b76641

Change-Id: I16fc2fe2ad37cec0fb7c20376d6bc285c0020eff

7 years agoMerge "libblkid: fix buffer overflow scanning partition name"
Jin Qian [Mon, 24 Apr 2017 18:41:46 +0000 (18:41 +0000)]
Merge "libblkid: fix buffer overflow scanning partition name"
am: 0474c47c22

Change-Id: I6cb23da1861c8358fe5ff2b3e2334e4bf4218664

7 years agoMerge "libblkid: fix buffer overflow scanning partition name"
Treehugger Robot [Mon, 24 Apr 2017 17:51:34 +0000 (17:51 +0000)]
Merge "libblkid: fix buffer overflow scanning partition name"

7 years agolibblkid: fix buffer overflow scanning partition name
Jin Qian [Mon, 17 Apr 2017 23:13:20 +0000 (16:13 -0700)]
libblkid: fix buffer overflow scanning partition name

If "line" is carefully crafted, sscanf will write 1 byte over ptname.

Bug: 36103037
Change-Id: Ia19e032d7c65edc27373ebccc0a5569f0fa31161

7 years agoRevert "Add "libc" to soong static_executable targets."
Jeff Gaston [Thu, 16 Mar 2017 22:41:13 +0000 (15:41 -0700)]
Revert "Add "libc" to soong static_executable targets."

This reverts commit b799ad178fa18c2925a283206496d3f5d6e87f35.
It's no longer needed after https://android-review.googlesource.com/c/329298/

Bug: 34722432
Test: lunch aosp_arm-eng && mmma external/e2fsprogs
Change-Id: I4115fe89ef7751364053223be24e7682e66b6b67

7 years agoMerge "e2fsdroid: don't print empty files in block_list.c:end_new_file" am: 43ff4cf0d...
Ben Fennema [Tue, 14 Mar 2017 21:21:18 +0000 (21:21 +0000)]
Merge "e2fsdroid: don't print empty files in block_list.c:end_new_file" am: 43ff4cf0d8 am: dd62d63cd1
am: 1d8c36e7ae

Change-Id: Iea5425e6ba48a2ee893348ccdc40d099b3cd1ef8

7 years agoMerge "e2fsdroid: don't print empty files in block_list.c:end_new_file" am: 43ff4cf0d8
Ben Fennema [Tue, 14 Mar 2017 21:15:47 +0000 (21:15 +0000)]
Merge "e2fsdroid: don't print empty files in block_list.c:end_new_file" am: 43ff4cf0d8
am: dd62d63cd1

Change-Id: I44a9335693be5300560c6f02f71893633e11d8b3

7 years agoMerge "e2fsdroid: don't print empty files in block_list.c:end_new_file"
Ben Fennema [Tue, 14 Mar 2017 21:10:17 +0000 (21:10 +0000)]
Merge "e2fsdroid: don't print empty files in block_list.c:end_new_file"
am: 43ff4cf0d8

Change-Id: Id89e488be9554baf51aa4144dcd911b7fff4d32f

7 years agoMerge "e2fsdroid: don't print empty files in block_list.c:end_new_file"
Ben Fennema [Tue, 14 Mar 2017 21:04:51 +0000 (21:04 +0000)]
Merge "e2fsdroid: don't print empty files in block_list.c:end_new_file"

7 years agoe2fsdroid: don't print empty files in block_list.c:end_new_file
Ben Fennema [Thu, 9 Mar 2017 06:44:17 +0000 (22:44 -0800)]
e2fsdroid: don't print empty files in block_list.c:end_new_file

Change-Id: I4b38841c9c36a8faaa9f65bc7b61c7abdddab094
Signed-off-by: Ben Fennema <fennema@google.com>
7 years agoMerge "blkid: add support to recognize exfat to blkid." am: 070a4b0d99 am: bd16b7be12
liminghao [Thu, 2 Mar 2017 17:50:54 +0000 (17:50 +0000)]
Merge "blkid: add support to recognize exfat to blkid." am: 070a4b0d99 am: bd16b7be12
am: 6648b16d19

Change-Id: Ib7fc6e989a67bbca2261fa374887ec07946dbb98

7 years agoMerge "blkid: add support to recognize exfat to blkid." am: 070a4b0d99
liminghao [Thu, 2 Mar 2017 17:48:24 +0000 (17:48 +0000)]
Merge "blkid: add support to recognize exfat to blkid." am: 070a4b0d99
am: bd16b7be12

Change-Id: I4f352e2deb6dc927a5dcf914e4ab8fe716dd91a4

7 years agoMerge "blkid: add support to recognize exfat to blkid."
liminghao [Thu, 2 Mar 2017 17:46:55 +0000 (17:46 +0000)]
Merge "blkid: add support to recognize exfat to blkid."
am: 070a4b0d99

Change-Id: I20a4a1f00af496ffc878a43e9dba60d24548ab09

7 years agoMerge "blkid: add support to recognize exfat to blkid."
Treehugger Robot [Thu, 2 Mar 2017 17:42:37 +0000 (17:42 +0000)]
Merge "blkid: add support to recognize exfat to blkid."

7 years agoblkid: add support to recognize exfat to blkid.
liminghao [Wed, 1 Mar 2017 09:54:42 +0000 (17:54 +0800)]
blkid: add support to recognize exfat to blkid.

we can now identify exfat filesystem.

Change-Id: I870e59a14b6bcd8b45562cdd02c2502d60a9eeff
Signed-off-by: liminghao <liminghao@xiaomi.com>
7 years agoMerge "e2fsck: exit with exit status 0 if no errors were fixed" am: 82f3d0584c am...
Theodore Ts'o [Tue, 28 Feb 2017 01:24:19 +0000 (01:24 +0000)]
Merge "e2fsck: exit with exit status 0 if no errors were fixed" am: 82f3d0584c am: ba0844f8c7
am: a9f981de18

Change-Id: I888600261f4f12cadc56255101f6de5c3d495f29

7 years agoMerge "e2fsck: exit with exit status 0 if no errors were fixed" am: 82f3d0584c
Theodore Ts'o [Tue, 28 Feb 2017 01:21:49 +0000 (01:21 +0000)]
Merge "e2fsck: exit with exit status 0 if no errors were fixed" am: 82f3d0584c
am: ba0844f8c7

Change-Id: I4f4faf0007fa8a59e447013d0d2c2323f5713d0d

7 years agoMerge "e2fsck: exit with exit status 0 if no errors were fixed"
Theodore Ts'o [Tue, 28 Feb 2017 01:19:50 +0000 (01:19 +0000)]
Merge "e2fsck: exit with exit status 0 if no errors were fixed"
am: 82f3d0584c

Change-Id: I2d5c70430675a0338fc219fc8f69cdbdac335e82

7 years agoMerge "e2fsck: exit with exit status 0 if no errors were fixed"
Treehugger Robot [Tue, 28 Feb 2017 01:16:00 +0000 (01:16 +0000)]
Merge "e2fsck: exit with exit status 0 if no errors were fixed"

7 years agoe2fsck: exit with exit status 0 if no errors were fixed
Theodore Ts'o [Fri, 17 Feb 2017 03:02:35 +0000 (22:02 -0500)]
e2fsck: exit with exit status 0 if no errors were fixed

Previously, e2fsck would exit with a status code of 1 even though the
only changes that it made to the file system were various
optimziations and not fixing file system corruption.  Since the man
page states that an exit status of 1 means "file system errors
corrupted", fix e2fsck to return an exit status of 0.

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
7 years agoMerge "Disable macro redefined warnings." am: 0a9866d60b am: 9bbfd91413
Christopher Ferris [Mon, 27 Feb 2017 20:27:45 +0000 (20:27 +0000)]
Merge "Disable macro redefined warnings." am: 0a9866d60b am: 9bbfd91413
am: a091d1cfbf

Change-Id: I2077cce88a448ed86bb85b39cba767f930a287e3

7 years agoMerge "Disable macro redefined warnings." am: 0a9866d60b
Christopher Ferris [Mon, 27 Feb 2017 20:23:42 +0000 (20:23 +0000)]
Merge "Disable macro redefined warnings." am: 0a9866d60b
am: 9bbfd91413

Change-Id: I99cf61b4953f53f349518b64ad1c84d3e3de7037

7 years agoMerge "Disable macro redefined warnings."
Christopher Ferris [Mon, 27 Feb 2017 20:16:59 +0000 (20:16 +0000)]
Merge "Disable macro redefined warnings."
am: 0a9866d60b

Change-Id: Ieca574c841b5d73b991cd119878dcbf1f73781eb

7 years agoMerge "Disable macro redefined warnings."
Christopher Ferris [Mon, 27 Feb 2017 20:09:54 +0000 (20:09 +0000)]
Merge "Disable macro redefined warnings."

7 years agoDisable macro redefined warnings.
Christopher Ferris [Thu, 23 Feb 2017 23:36:54 +0000 (15:36 -0800)]
Disable macro redefined warnings.

The new kernel headers do:

  #define __bitwise __bitwise__

However, the code redefines __bitwise without undef'ing it first.

This is a temporary fix, b/35721782 filed to fix this.

Change-Id: I2c6a64146966f1737835f012d24ccc844570d02b
Test: Builds without warningers/errors.

7 years agoMerge "Add "libc" to soong static_executable targets." am: 98f63cd9de am: ea7db4e63a...
Alex Deymo [Thu, 26 Jan 2017 02:43:40 +0000 (02:43 +0000)]
Merge "Add "libc" to soong static_executable targets." am: 98f63cd9de am: ea7db4e63a am: 668ec9e6b6
am: a0ad535dcd

Change-Id: Ifb15f1cf46e68219346dcd7a0ed909b6a8b2473c

7 years agoMerge "Add "libc" to soong static_executable targets." am: 98f63cd9de am: ea7db4e63a
Alex Deymo [Thu, 26 Jan 2017 02:40:39 +0000 (02:40 +0000)]
Merge "Add "libc" to soong static_executable targets." am: 98f63cd9de am: ea7db4e63a
am: 668ec9e6b6

Change-Id: I29edac9d49075bae0cfa8d335d8694e0d9751c0d

7 years agoMerge "Add "libc" to soong static_executable targets." am: 98f63cd9de
Alex Deymo [Thu, 26 Jan 2017 02:38:10 +0000 (02:38 +0000)]
Merge "Add "libc" to soong static_executable targets." am: 98f63cd9de
am: ea7db4e63a

Change-Id: Ia3107fb2fd6300980f0e451a98caaddb5087811e

7 years agoMerge "Add "libc" to soong static_executable targets."
Alex Deymo [Thu, 26 Jan 2017 02:35:39 +0000 (02:35 +0000)]
Merge "Add "libc" to soong static_executable targets."
am: 98f63cd9de

Change-Id: I7455d4552d82cc80d87edc5383ca34bce77be2f9

7 years agoMerge "Add "libc" to soong static_executable targets."
Alex Deymo [Thu, 26 Jan 2017 02:30:25 +0000 (02:30 +0000)]
Merge "Add "libc" to soong static_executable targets."

7 years agoAdd "libc" to soong static_executable targets.
Alex Deymo [Thu, 26 Jan 2017 01:47:50 +0000 (17:47 -0800)]
Add "libc" to soong static_executable targets.

When building a static exectuable for "arm", the libgcc is automatically
included by the build system *after* libc, but libgcc has some symbol
dependencies on "libc", like for example the "raise" symbol.

libgcc, libatomic and libcompiler_rt-extras are passed in a group
(enclosed by --start-group and --end-group) so they all are included
regardless of the order inside that group. Nevertheless libc only
appears outside this group and before them, so the undefined references
from libgcc are not resolved.

This patch adds "libc" as a explicit static_libs dependency to
static_executable targets forcing it to be included in the group.

Bug: 34220783
Test: mmma external/e2fsprogs
Change-Id: Ia18db10da0f18494600d7e0c870291902d71b287

7 years agoMerge "Convert e2fsprogs targets to soong." am: 6091a50d7a am: 19f945ac14 am: 006bf071cd
Alex Deymo [Thu, 26 Jan 2017 00:01:45 +0000 (00:01 +0000)]
Merge "Convert e2fsprogs targets to soong." am: 6091a50d7a am: 19f945ac14 am: 006bf071cd
am: 0c0ecab090

Change-Id: I6e3cbfe0166194d57e88152939070b5b73d93d87

7 years agoMerge "Convert e2fsprogs targets to soong." am: 6091a50d7a am: 19f945ac14
Alex Deymo [Wed, 25 Jan 2017 23:59:10 +0000 (23:59 +0000)]
Merge "Convert e2fsprogs targets to soong." am: 6091a50d7a am: 19f945ac14
am: 006bf071cd

Change-Id: I2d18a61cf9b2b0439f98350668fe309d94809dce

7 years agoMerge "Convert e2fsprogs targets to soong." am: 6091a50d7a
Alex Deymo [Wed, 25 Jan 2017 23:56:06 +0000 (23:56 +0000)]
Merge "Convert e2fsprogs targets to soong." am: 6091a50d7a
am: 19f945ac14

Change-Id: Ic9e7214abd359c24f33e273295584d174c701d0a

7 years agoMerge "Convert e2fsprogs targets to soong."
Alex Deymo [Wed, 25 Jan 2017 23:53:09 +0000 (23:53 +0000)]
Merge "Convert e2fsprogs targets to soong."
am: 6091a50d7a

Change-Id: Iacf1c8b33da19ed46009f60416cf65af18736296

7 years agoMerge "Convert e2fsprogs targets to soong."
Alex Deymo [Wed, 25 Jan 2017 23:48:42 +0000 (23:48 +0000)]
Merge "Convert e2fsprogs targets to soong."

7 years agoConvert e2fsprogs targets to soong.
Alex Deymo [Thu, 12 Jan 2017 17:48:04 +0000 (09:48 -0800)]
Convert e2fsprogs targets to soong.

This patch also removes all the "-host" and "_static" suffix from all
the libraries adding "unique_host_soname: true". This prevents
confusions with the host installed libraries.

A new "libext2_misc" library is introduced to export some files from
the misc/ directory to other binaries in this project.

Bug: 34220783
Test: mmma external/e2fsprogs

Change-Id: Ia1b689991346b11f8cb38f7c6ee356e666e01d6d

7 years agoMerge "HACK: android: exit(1) if selabel_lookup fails" am: 412c46afdf am: 6c826a6fc9...
Nick Kralevich [Thu, 19 Jan 2017 03:46:37 +0000 (03:46 +0000)]
Merge "HACK: android: exit(1) if selabel_lookup fails" am: 412c46afdf am: 6c826a6fc9 am: d775c7038b
am: d4bfd33a0e

Change-Id: Icc046814e68891473b4550a55c87fd4e9a11f26b

7 years agoMerge "HACK: android: exit(1) if selabel_lookup fails" am: 412c46afdf am: 6c826a6fc9
Nick Kralevich [Thu, 19 Jan 2017 03:44:08 +0000 (03:44 +0000)]
Merge "HACK: android: exit(1) if selabel_lookup fails" am: 412c46afdf am: 6c826a6fc9
am: d775c7038b

Change-Id: I3d1bc996c98cc328d439adc741a1623b7fa8841b

7 years agoMerge "HACK: android: exit(1) if selabel_lookup fails" am: 412c46afdf
Nick Kralevich [Thu, 19 Jan 2017 03:42:07 +0000 (03:42 +0000)]
Merge "HACK: android: exit(1) if selabel_lookup fails" am: 412c46afdf
am: 6c826a6fc9

Change-Id: I4abfb2ae25b498ede40399d6a5226b90f8f28687

7 years agoMerge "HACK: android: exit(1) if selabel_lookup fails"
Nick Kralevich [Thu, 19 Jan 2017 03:40:08 +0000 (03:40 +0000)]
Merge "HACK: android: exit(1) if selabel_lookup fails"
am: 412c46afdf

Change-Id: Id888c5744571575ba62f3ee6c54222d88a86c639

7 years agoMerge "HACK: android: exit(1) if selabel_lookup fails"
Treehugger Robot [Thu, 19 Jan 2017 03:36:37 +0000 (03:36 +0000)]
Merge "HACK: android: exit(1) if selabel_lookup fails"

7 years agoHACK: android: exit(1) if selabel_lookup fails
Nick Kralevich [Wed, 18 Jan 2017 23:17:42 +0000 (15:17 -0800)]
HACK: android: exit(1) if selabel_lookup fails

If selabel_lookup fails, the current implementation of set_selinux_xattr
returns -1, but the command line tool e2fsdroid reports success.
There's a bunch of things wrong:

1) -1 does not appear to be a legal errcode_t value. The appropriate
return value appears to be DIRENT_ABORT.
2) A return value of DIRENT_ABORT is ignored by the upper layers of the
code.
3) Attempting to fix the upper layers of the code to not ignore
DIRENT_ABORT results in complaints about not being able to create
/lost+found.

Call stack:

- main
 - android_configure_fs
  - __android_configure_fs
   - ext2fs_dir_iterate2
    - ext2fs_block_iterate3
     - ext2fs_process_dir_block
      - walk_dir
       - ext2fs_dir_iterate2
        - ext2fs_block_iterate3
         - ext2fs_process_dir_block
          - walk_dir
           - ext2fs_dir_iterate2
            - ext2fs_block_iterate3
             - ext2fs_process_dir_block
              - androidify_inode
               - set_selinux_xattr

I'm honestly not sure how to fix this, so just throw an exit(1) in
there, to make sure the program dies a horrible death if
selabel_lookup() fails. This is much better than the alternative of
e2fsdroid returning success with an improperly labeled file.

Bug: 34358308
Test: Artifically modify selabel_lookup() to return a failure, and
      verify Android doesn't compile.
Test: Verify Android compiles under normal circumstances.
Change-Id: I60e04bc6559a66d3f3202f2c28e2519856385ded

7 years agoMerge "Remove "_host" and "_static" suffix from libsparse." am: 22aabbe13b am: 7d9532...
Alex Deymo [Thu, 12 Jan 2017 22:45:32 +0000 (22:45 +0000)]
Merge "Remove "_host" and "_static" suffix from libsparse." am: 22aabbe13b am: 7d95329bf0 am: 2b89372afa
am: efc917faf4

Change-Id: I3c500ff9dcc34851e57661cff906d13fa08127f1

7 years agoMerge "Remove "_host" and "_static" suffix from libsparse." am: 22aabbe13b am: 7d95329bf0
Alex Deymo [Thu, 12 Jan 2017 21:37:40 +0000 (21:37 +0000)]
Merge "Remove "_host" and "_static" suffix from libsparse." am: 22aabbe13b am: 7d95329bf0
am: 2b89372afa

Change-Id: I73fef47b73440c2292f0dac47e98b57ff347875b

7 years agoMerge "Remove "_host" and "_static" suffix from libsparse." am: 22aabbe13b
Alex Deymo [Thu, 12 Jan 2017 21:32:41 +0000 (21:32 +0000)]
Merge "Remove "_host" and "_static" suffix from libsparse." am: 22aabbe13b
am: 7d95329bf0

Change-Id: Ieb969d6353c3ac9f33e65d220f7cb1c67ca3791b

7 years agoMerge "Remove "_host" and "_static" suffix from libsparse."
Alex Deymo [Thu, 12 Jan 2017 21:27:41 +0000 (21:27 +0000)]
Merge "Remove "_host" and "_static" suffix from libsparse."
am: 22aabbe13b

Change-Id: I1bcdcfcc66b7db716cb5071e5f1ed3519b6b935b

7 years agoMerge "Remove "_host" and "_static" suffix from libsparse."
Alex Deymo [Thu, 12 Jan 2017 21:23:09 +0000 (21:23 +0000)]
Merge "Remove "_host" and "_static" suffix from libsparse."

7 years agoRemove "_host" and "_static" suffix from libsparse.
Alex Deymo [Wed, 11 Jan 2017 22:40:43 +0000 (14:40 -0800)]
Remove "_host" and "_static" suffix from libsparse.

Bug: 34220783
Change-Id: I218ab40f423bf0bddebc3b2e1526bd9e3549eed6

7 years agoMerge "libext2fs: fix sparse param parsing on mac build" am: b6da61cd92 am: 5412034d8...
Jin Qian [Sun, 8 Jan 2017 10:04:24 +0000 (10:04 +0000)]
Merge "libext2fs: fix sparse param parsing on mac build" am: b6da61cd92 am: 5412034d84 am: c1debb2e9a
am: 197f720364

Change-Id: Idca90e077b29bb0875f969961748fbf4b1736748

7 years agoMerge "libext2fs: fix sparse param parsing on mac build" am: b6da61cd92 am: 5412034d84
Jin Qian [Sun, 8 Jan 2017 07:22:43 +0000 (07:22 +0000)]
Merge "libext2fs: fix sparse param parsing on mac build" am: b6da61cd92 am: 5412034d84
am: c1debb2e9a

Change-Id: Iaf9d2e63a7197049dd7a565bb649e45eac41de93

7 years agoMerge "libext2fs: fix sparse param parsing on mac build" am: b6da61cd92
Jin Qian [Sun, 8 Jan 2017 07:18:14 +0000 (07:18 +0000)]
Merge "libext2fs: fix sparse param parsing on mac build" am: b6da61cd92
am: 5412034d84

Change-Id: Icc7b4d6f8e2819f811a69abe91f44ce2bb20e054

7 years agoMerge "libext2fs: fix sparse param parsing on mac build"
Jin Qian [Sun, 8 Jan 2017 07:13:44 +0000 (07:13 +0000)]
Merge "libext2fs: fix sparse param parsing on mac build"
am: b6da61cd92

Change-Id: Ice8c98f8fd072b157ec91310078d11120cc5c4ca

7 years agoMerge "libext2fs: fix sparse param parsing on mac build"
Treehugger Robot [Sun, 8 Jan 2017 07:10:49 +0000 (07:10 +0000)]
Merge "libext2fs: fix sparse param parsing on mac build"

7 years agolibext2fs: fix sparse param parsing on mac build
Jin Qian [Sat, 7 Jan 2017 00:30:34 +0000 (16:30 -0800)]
libext2fs: fix sparse param parsing on mac build

Flag m is not supported on macos sscanf. Fall back to manually
allocate the string.

Use strict format to skip ":" between params.

Change-Id: Ic4f3747708423d0504ea40fb5cb116068f4a7ab8

7 years agoMerge changes from topic 'e2fsdroid' am: da08ba0d8a am: 80339f777f am: 0607ed1ebe
Jin Qian [Tue, 3 Jan 2017 21:00:06 +0000 (21:00 +0000)]
Merge changes from topic 'e2fsdroid' am: da08ba0d8a am: 80339f777f am: 0607ed1ebe
am: 4a56d3883e

Change-Id: Id1106338e80e37e34736ebda5c1b8644850e8a81

7 years agoe2fsdroid: report error from ext2fs am: 948b9fecf8 am: 9ae7a1821e am: ec8a1df915
Jin Qian [Tue, 3 Jan 2017 21:00:04 +0000 (21:00 +0000)]
e2fsdroid: report error from ext2fs am: 948b9fecf8 am: 9ae7a1821e am: ec8a1df915
am: e855e58bbd

Change-Id: I92f3444e1d2c461b96c38dee24435c98fc7fcce9

7 years agoe2fsdroid: set timestamp based on source files am: d882f1e231 am: 67447e52c6 am:...
Jin Qian [Tue, 3 Jan 2017 21:00:01 +0000 (21:00 +0000)]
e2fsdroid: set timestamp based on source files am: d882f1e231 am: 67447e52c6 am: c66c7aa414
am: 4167af08be

Change-Id: Id24c3496fc4e2a60c1671e17039ecb5dafae3b5c

7 years agoe2fsdroid: use absolute path for product_out am: bc02ac42b2 am: b7a39c5443 am: b22693a64f
Jin Qian [Tue, 3 Jan 2017 20:59:58 +0000 (20:59 +0000)]
e2fsdroid: use absolute path for product_out am: bc02ac42b2 am: b7a39c5443 am: b22693a64f
am: 85267f0452

Change-Id: I61939b6dde1b0dd13f3eeb484f362ccb308fe95d

7 years agolibext2fs: merge contiguous data blocks when writing to sparse file am: 6ef6efab23...
Jin Qian [Tue, 3 Jan 2017 20:59:55 +0000 (20:59 +0000)]
libext2fs: merge contiguous data blocks when writing to sparse file am: 6ef6efab23 am: 4059037c17 am: a6dc5be0ea
am: 8cad9ea0dd

Change-Id: I1b3452c50d0a6ebeb362e4471ddccf7ddfd7873e

7 years agoe2fsdroid: remove extra "/" when mountpoint is "/" am: 7fe49140ef am: a0ca66bb4d...
Jin Qian [Tue, 3 Jan 2017 20:59:54 +0000 (20:59 +0000)]
e2fsdroid: remove extra "/" when mountpoint is "/" am: 7fe49140ef am: a0ca66bb4d am: c71f3b11a1
am: 9645a95660

Change-Id: I4abc9f09723ce7271ce11634e22d411c321dd2ad

7 years agoMerge changes from topic 'e2fsdroid' am: da08ba0d8a am: 80339f777f
Jin Qian [Tue, 3 Jan 2017 20:51:39 +0000 (20:51 +0000)]
Merge changes from topic 'e2fsdroid' am: da08ba0d8a am: 80339f777f
am: 0607ed1ebe

Change-Id: I02c39b403d65b266464166a9383b88c690e4253f

7 years agoe2fsdroid: report error from ext2fs am: 948b9fecf8 am: 9ae7a1821e
Jin Qian [Tue, 3 Jan 2017 20:51:36 +0000 (20:51 +0000)]
e2fsdroid: report error from ext2fs am: 948b9fecf8 am: 9ae7a1821e
am: ec8a1df915

Change-Id: I9de2920f4464ddb500db70d7ed00e6740c6a7fe3

7 years agoe2fsdroid: set timestamp based on source files am: d882f1e231 am: 67447e52c6
Jin Qian [Tue, 3 Jan 2017 20:51:33 +0000 (20:51 +0000)]
e2fsdroid: set timestamp based on source files am: d882f1e231 am: 67447e52c6
am: c66c7aa414

Change-Id: I5ecc3e7fbbcf981f121210985cc90673a787366d

7 years agoe2fsdroid: use absolute path for product_out am: bc02ac42b2 am: b7a39c5443
Jin Qian [Tue, 3 Jan 2017 20:51:29 +0000 (20:51 +0000)]
e2fsdroid: use absolute path for product_out am: bc02ac42b2 am: b7a39c5443
am: b22693a64f

Change-Id: Ia046e04ed9fce21efcc68611aad0d9d5e3888c20

7 years agolibext2fs: merge contiguous data blocks when writing to sparse file am: 6ef6efab23...
Jin Qian [Tue, 3 Jan 2017 20:51:26 +0000 (20:51 +0000)]
libext2fs: merge contiguous data blocks when writing to sparse file am: 6ef6efab23 am: 4059037c17
am: a6dc5be0ea

Change-Id: I5c9ab5d7fa00ed2fc1cc135f48a47f93dfe2d19f

7 years agoe2fsdroid: remove extra "/" when mountpoint is "/" am: 7fe49140ef am: a0ca66bb4d
Jin Qian [Tue, 3 Jan 2017 20:51:23 +0000 (20:51 +0000)]
e2fsdroid: remove extra "/" when mountpoint is "/" am: 7fe49140ef am: a0ca66bb4d
am: c71f3b11a1

Change-Id: Id302fde4eb450b64dcbd3ca102253613dfd5ca17

7 years agoMerge changes from topic 'e2fsdroid' am: da08ba0d8a
Jin Qian [Tue, 3 Jan 2017 20:44:04 +0000 (20:44 +0000)]
Merge changes from topic 'e2fsdroid' am: da08ba0d8a
am: 80339f777f

Change-Id: Ic1c4965089d18636bb2603c65f6d1cad8a316900

7 years agoe2fsdroid: report error from ext2fs am: 948b9fecf8
Jin Qian [Tue, 3 Jan 2017 20:44:03 +0000 (20:44 +0000)]
e2fsdroid: report error from ext2fs am: 948b9fecf8
am: 9ae7a1821e

Change-Id: I729e6b28d8481ca5dabbb879176211e70ca57bc5

7 years agoe2fsdroid: set timestamp based on source files am: d882f1e231
Jin Qian [Tue, 3 Jan 2017 20:44:01 +0000 (20:44 +0000)]
e2fsdroid: set timestamp based on source files am: d882f1e231
am: 67447e52c6

Change-Id: I79a664f5113bdd4818434081f9e399a730fbe6f1

7 years agoe2fsdroid: use absolute path for product_out am: bc02ac42b2
Jin Qian [Tue, 3 Jan 2017 20:43:58 +0000 (20:43 +0000)]
e2fsdroid: use absolute path for product_out am: bc02ac42b2
am: b7a39c5443

Change-Id: I06917969f807e283409c516e25f8643844c9c8c9

7 years agolibext2fs: merge contiguous data blocks when writing to sparse file am: 6ef6efab23
Jin Qian [Tue, 3 Jan 2017 20:43:54 +0000 (20:43 +0000)]
libext2fs: merge contiguous data blocks when writing to sparse file am: 6ef6efab23
am: 4059037c17

Change-Id: Id545cb1245532699024aee376b9c80f1d253ef2e

7 years agoe2fsdroid: remove extra "/" when mountpoint is "/" am: 7fe49140ef
Jin Qian [Tue, 3 Jan 2017 20:43:52 +0000 (20:43 +0000)]
e2fsdroid: remove extra "/" when mountpoint is "/" am: 7fe49140ef
am: a0ca66bb4d

Change-Id: I81465ccb4c3c56e8429d2cb22c9b447d74f655db

7 years agoMerge changes from topic 'e2fsdroid'
Jin Qian [Tue, 3 Jan 2017 20:36:03 +0000 (20:36 +0000)]
Merge changes from topic 'e2fsdroid'
am: da08ba0d8a

Change-Id: Id1c63aa261fa13df85422999ba00cadea7bf5eec

7 years agoe2fsdroid: report error from ext2fs
Jin Qian [Tue, 3 Jan 2017 20:36:02 +0000 (20:36 +0000)]
e2fsdroid: report error from ext2fs
am: 948b9fecf8

Change-Id: I3d8619f350faa23ca2e4b257a37252c0761adf92

7 years agoe2fsdroid: set timestamp based on source files
Jin Qian [Tue, 3 Jan 2017 20:35:59 +0000 (20:35 +0000)]
e2fsdroid: set timestamp based on source files
am: d882f1e231

Change-Id: I5fe8c55f89d597fb056a25097fe3fbbfcf8133c1

7 years agoe2fsdroid: use absolute path for product_out
Jin Qian [Tue, 3 Jan 2017 20:35:57 +0000 (20:35 +0000)]
e2fsdroid: use absolute path for product_out
am: bc02ac42b2

Change-Id: I81da9836e33c56d440896896ffe5519ca12ff63c