Whamcloud - gitweb
AOSP: e2fsdroid: Correctly process the root inode
authorLuis Hector Chavez <lhchavez@google.com>
Tue, 19 Jun 2018 21:50:40 +0000 (14:50 -0700)
committerTheodore Ts'o <tytso@mit.edu>
Sun, 24 Jun 2018 03:18:48 +0000 (23:18 -0400)
commit8459c40913d393bfb22ae8b2ef7d7daa05b653c1
tree4922723cdc441a756f3bb34b70fb986f21f2763a
parentf0d1a5099c721374e93a7c562e76d1e97f3e2520
AOSP: e2fsdroid: Correctly process the root inode

This change ensures that the root inode has the correct uid/gid by
calling androidify_inode() on it. It also sets android_configure = 1
when the u/gid mapping is provided.

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Google-Bug-Id: 78561186
Google-Bug-Id: 110415537
Test: $ m  # With BOARD_SYSTEMIMAGE_UID_MAP=655360 0 5000
      $ simg2img ${OUT}/{system.img,system.raw.img}
      $ mkdir tmp
      $ sudo mount -o loop ${OUT}/system.raw.img tmp
      $ stat --format="%u %g" tmp
      655360 655360
Change-Id: I842a32b6d64439f9f16b9c6b66de20d4e4418aa8
From AOSP commit: ee3f0f37c34d68aa7a96a36dea369acae312772c
contrib/android/e2fsdroid.c
contrib/android/perms.c