OSDN Git Service

Plumb through volume UUID when building paths.
authorJeff Sharkey <jsharkey@android.com>
Wed, 8 Apr 2015 01:14:05 +0000 (18:14 -0700)
committerJeff Sharkey <jsharkey@android.com>
Wed, 8 Apr 2015 03:13:27 +0000 (20:13 -0700)
commitc03de09173f98506e73e7cf7df21fe11795d4b24
tree52f975303151eb1319acdb7a6a03c3d0042d0c2a
parent00afb8177fdbf144c75c00e9eacc915589807d35
Plumb through volume UUID when building paths.

Since app data paths can live on expanded storage devices, accept the
target volume UUID when building paths.  The null UUID indicates the
default internal storage.

To improve readability, start using std::string in several places,
which throws when allocations fail.  For now, perform last-second
sanity checks on incoming path arguments, but we'll eventually want
to check arguments as they come through installd.cpp, instead of
crashing the entire daemon.

Also remove "lib" symlink code from install() and make_user_data(),
since we're no longer supporting /data/app-lib.  The framework
already uses linklib() to create the right symlink for the selected
ISA-specific library dir.

Bug: 19993667
Change-Id: Ib9343575ffb62bf3981e19375de8f3822fc31e28
cmds/installd/Android.mk
cmds/installd/commands.cpp
cmds/installd/installd.cpp
cmds/installd/installd.h
cmds/installd/tests/Android.mk
cmds/installd/tests/installd_utils_test.cpp
cmds/installd/utils.cpp