diff options
author | Kenny Root <kroot@google.com> | 2012-07-31 09:34:26 -0700 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2012-07-31 09:34:26 -0700 |
commit | b3e4b46db028c35d6d12c5f8f25b0463833fb51d (patch) | |
tree | ac0814988205812fd5d4c538485316c982d843d3 /cmds/installd | |
parent | 5dcbe638ee063201fb476ef475d2beb347f02097 (diff) | |
parent | e583bcf13c13957bdf20f8bc5e23258b083b2f51 (diff) | |
download | frameworks_base-b3e4b46db028c35d6d12c5f8f25b0463833fb51d.zip frameworks_base-b3e4b46db028c35d6d12c5f8f25b0463833fb51d.tar.gz frameworks_base-b3e4b46db028c35d6d12c5f8f25b0463833fb51d.tar.bz2 |
am e583bcf1: Merge "Explicitly set lib dir permissions during unlink" into jb-dev
* commit 'e583bcf13c13957bdf20f8bc5e23258b083b2f51':
Explicitly set lib dir permissions during unlink
Diffstat (limited to 'cmds/installd')
-rw-r--r-- | cmds/installd/commands.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/cmds/installd/commands.c b/cmds/installd/commands.c index 8b11d02..41e7b8d 100644 --- a/cmds/installd/commands.c +++ b/cmds/installd/commands.c @@ -1094,7 +1094,12 @@ int unlinklib(const char* dataDir) rc = -errno; goto out; } - + if (chmod(libdir, 0755) < 0) { + ALOGE("cannot chmod dir '%s': %s\n", libdir, strerror(errno)); + unlink(libdir); + rc = -errno; + goto out; + } if (chown(libdir, AID_SYSTEM, AID_SYSTEM) < 0) { ALOGE("cannot chown dir '%s': %s\n", libdir, strerror(errno)); unlink(libdir); |