aboutsummaryrefslogtreecommitdiffstats
path: root/minzip
diff options
context:
space:
mode:
authorNick Kralevich <nnk@google.com>2013-09-09 10:47:14 -0700
committerNick Kralevich <nnk@google.com>2013-09-09 10:47:14 -0700
commit3328e3bc81161c2a57ea94d304162276facdd826 (patch)
treeecd8762bc38d8db05b1175ec392ae3ed54cbd0a8 /minzip
parent3b5a987cd7fd76c038e9875b430028216d21ace3 (diff)
downloadbootable_recovery-3328e3bc81161c2a57ea94d304162276facdd826.zip
bootable_recovery-3328e3bc81161c2a57ea94d304162276facdd826.tar.gz
bootable_recovery-3328e3bc81161c2a57ea94d304162276facdd826.tar.bz2
Revert "Update OTA installer to understand SELinux filesystem labels"
This reverts commit 627eb30f73c29257acaeb6568f3da38880784f7c. Bug: 10183961 Bug: 10186213
Diffstat (limited to 'minzip')
-rw-r--r--minzip/DirUtil.c9
-rw-r--r--minzip/DirUtil.h2
2 files changed, 3 insertions, 8 deletions
diff --git a/minzip/DirUtil.c b/minzip/DirUtil.c
index c120fa3..8dd5da1 100644
--- a/minzip/DirUtil.c
+++ b/minzip/DirUtil.c
@@ -23,7 +23,6 @@
#include <errno.h>
#include <dirent.h>
#include <limits.h>
-#include <selinux/selinux.h>
#include "DirUtil.h"
@@ -238,7 +237,7 @@ dirUnlinkHierarchy(const char *path)
int
dirSetHierarchyPermissions(const char *path,
- int uid, int gid, int dirMode, int fileMode, const char* secontext)
+ int uid, int gid, int dirMode, int fileMode)
{
struct stat st;
if (lstat(path, &st)) {
@@ -256,10 +255,6 @@ dirSetHierarchyPermissions(const char *path,
return -1;
}
- if ((secontext != NULL) && lsetfilecon(path, secontext) && (errno != ENOTSUP)) {
- return -1;
- }
-
/* recurse over directory components */
if (S_ISDIR(st.st_mode)) {
DIR *dir = opendir(path);
@@ -276,7 +271,7 @@ dirSetHierarchyPermissions(const char *path,
char dn[PATH_MAX];
snprintf(dn, sizeof(dn), "%s/%s", path, de->d_name);
- if (!dirSetHierarchyPermissions(dn, uid, gid, dirMode, fileMode, secontext)) {
+ if (!dirSetHierarchyPermissions(dn, uid, gid, dirMode, fileMode)) {
errno = 0;
} else if (errno == 0) {
errno = -1;
diff --git a/minzip/DirUtil.h b/minzip/DirUtil.h
index 3e12a0b..a5cfa76 100644
--- a/minzip/DirUtil.h
+++ b/minzip/DirUtil.h
@@ -54,7 +54,7 @@ int dirUnlinkHierarchy(const char *path);
* Sets directories to <dirMode> and files to <fileMode>. Skips symlinks.
*/
int dirSetHierarchyPermissions(const char *path,
- int uid, int gid, int dirMode, int fileMode, const char* secontext);
+ int uid, int gid, int dirMode, int fileMode);
#ifdef __cplusplus
}