OSDN Git Service

Null-terminate readlink() result, full remount.
authorJeff Sharkey <jsharkey@android.com>
Tue, 30 Jun 2015 22:54:17 +0000 (15:54 -0700)
committerJeff Sharkey <jsharkey@android.com>
Tue, 30 Jun 2015 22:54:17 +0000 (15:54 -0700)
commitc7b5b570bd05ed3bc921b0c2dc346416a52b4e3e
treec965045b40a2f0add98f5994793211bf8411ed84
parent63123c067a4e709198d9b8d3279c98561f8c990e
Null-terminate readlink() result, full remount.

In order to compare results from readlink() calls, we need to null
terminate the read value, otherwise we can end up doing an infinitely
recursive remount in the root namespace.

When remounting inside a namespace, unmount all existing mounts before
mounting the new storage into place.  This also means we need to mount
the user-specific symlinks back into place.

Skip spinning up the FUSE daemon when not visible, otherwise we get
stuck waiting for a daemon that never shows up.

Bug: 2219251822204412
Change-Id: Icc7db822354ab7ffc47c39cd0611f65edecc32e5
EmulatedVolume.cpp
PublicVolume.cpp
VolumeManager.cpp