rootdir: Add support for init.d

Change-Id: I0e4ada47752fee3b26c921523ab0f5630e5b59d4
Signed-off-by: Rob Beane <robbeane@gmail.com>
rootdir: Import init.superuser.rc to init.rc

Change-Id: I54542c6d3a48bbe0f98af0e9a35a4c1ba8772bd1
Signed-off-by: Rob Beane <robbeane@gmail.com>
Fix a bunch of small system/core bugs.

Missing frees in:
  adb/file_sync_client.c
  fastboot/fastboot.c
  libsparse/output_file.c

Missing closedirs in:
  adb/file_sync_service.c
  cpio/mkbootfs.c
  libcutils/dir_hash.c

Potential buffer overrun in:
  gpttool/gpttool.c

Incorrect NULL check in:
  libsparse/backed_block.c

Bug: https://code.google.com/p/android/issues/detail?id=61564
Change-Id: If97838a9e73a77aef7f416c31c237ce1fca4ce21
Signed-off-by: Rob Beane <robbeane@gmail.com>