From 9157d3f3b70f5225e06b0a478f2d3c5ce3d923b2 Mon Sep 17 00:00:00 2001 From: Kenny Root Date: Mon, 22 Oct 2012 15:19:16 -0700 Subject: Clear data deletes too much Bug: 7389445 Change-Id: Ic12d7a8e37747dc1a9b71ec5f881b5e440e0a75e --- cmds/installd/commands.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cmds') diff --git a/cmds/installd/commands.c b/cmds/installd/commands.c index 8e4d7ed..387f33d 100644 --- a/cmds/installd/commands.c +++ b/cmds/installd/commands.c @@ -185,8 +185,8 @@ int delete_user_data(const char *pkgname, uid_t persona) if (create_pkg_path(pkgdir, pkgname, PKG_DIR_POSTFIX, persona)) return -1; - /* delete contents AND directory, no exceptions */ - return delete_dir_contents(pkgdir, 1, NULL); + /* delete contents, excluding "lib", but not the directory itself */ + return delete_dir_contents(pkgdir, 0, "lib"); } int make_user_data(const char *pkgname, uid_t uid, uid_t persona) -- cgit v1.1