Avoid dereferencing NULL pointer with memcmp in the test code.

Signed-Off-By: Bhanu Chetlapalli <bhanu@mips.com>
ext4_utils: Fix long symbolic links

When the target of a symbolic link is over 60 characters, make_ext4fs
fails to create the link.

Instead of allocating n bytes, n blocks of 4096 bytes was reserved,
and the allocated data was never attached to the inode.

Change-Id: I63a2e76166a2afc30734265324d5c5265cfa59ff
Signed-off-by: Christian Bejram <christian.bejram@stericsson.com>
Merge "ext4_utils: Fix long symbolic links"
am 16052ec5: Merge "ext4_utils: Fix long symbolic links"

* commit '16052ec56a0836db7de51d6ea4173c6b53f0a9b9':
  ext4_utils: Fix long symbolic links
am 585c219b: atrace: add support for tracing CPU idle events

* commit '585c219b9b7c2e89b8db6707cacdaf29c362e7ba':
  atrace: add support for tracing CPU idle events
am 80cb1550: Ignore SIGPIPE is some of the tools used via dumpstate

* commit '80cb15504324667c9934ff350afff48881613393':
  Ignore SIGPIPE is some of the tools used via dumpstate
am 83fdbb05: Add disk I/O tracing.

* commit '83fdbb05c39b030ef1e5b3a7db79c617114c20f4':
  Add disk I/O tracing.
Fixes to make_ext4fs when compiled with HAVE_SELINUX.

Fix a segfault in contents.c.

Change-Id: I77c39b2cda5f3aa572b5ed8a4f2e5da78341eed6
Merge "Fixes to make_ext4fs when compiled with HAVE_SELINUX."
am 47aa1049: Merge "Fixes to make_ext4fs when compiled with HAVE_SELINUX."

* commit '47aa1049e80927420b59723806fab579997a7430':
  Fixes to make_ext4fs when compiled with HAVE_SELINUX.
am b9314021: atrace: enable running on user builds

* commit 'b9314021ee1ccaa62eb115e8e0188f482a950f3b':
  atrace: enable running on user builds
am 2633ce5c: Add some tools for testing ext4 performance and resiliency.

* commit '2633ce5ca5024d5565c9068c29ec39a8c3ed10e9':
  Add some tools for testing ext4 performance and resiliency.
am 32243fad: Fix a few bugs in rand_emmc_perf

* commit '32243fadeab8cf244861e3df89744b78ba3eff92':
  Fix a few bugs in rand_emmc_perf
Fix SELinux labeling for system.img

The system partition isn't getting labeled during the build.
This patch corrects that.
Signed-off-by: rpcraig <rpcraig@tycho.ncsc.mil>

Change-Id: I2695c60232935da272ac194fb9ece016c84b4593
Refactor sparse file support into libsparse

Minimal refactoring of output_file.c into libsparse in preparation
for completely separating libsparse from ext4_utils.

Moves output_file.c, backed_block.c, and parts of ext4_utils.c
into libsparse.  The only changes to the remanining files in
ext4_utils are using the new sparse.h header, and moving the
wipe call out of output_file.c and into make_ext4fs.c.

Change-Id: I1f66f6c3e05230a350023c5b4ea4422f16a73c4b
libsparse: make API sane

Replaces the libsparse API with a sane one based on an opaque
pointer.

Change-Id: I93bc9cf9a6b912a993ef554dbe6ffe2f0f723383
make_ext4fs: allow sparse gzip files

libsparse can handle sparse gzipped files, allow -s and -z together.

Change-Id: I32c336269375135af6be5d00a55604f8bf7619a3
system/extras/ext4_utils: move libsparse to system/core

Delete libsparse from ext4_utils, move it to system/core/libsparse in
preparation for linking tools in system/core against it.

Change-Id: I3545c2e0ad7122f99bbc998ab0e85ca1e65d5add
Merge changes I32c33626,I93bc9cf9,I1f66f6c3

* changes:
  make_ext4fs: allow sparse gzip files
  libsparse: make API sane
  Refactor sparse file support into libsparse
Merge "system/extras/ext4_utils: move libsparse to system/core"