diff options
author | Rob Landley <rob@landley.net> | 2005-05-03 06:25:50 +0000 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2005-05-03 06:25:50 +0000 |
commit | 60158cb93eb0b3207dd1084cdf5bdd9226bd9e89 (patch) | |
tree | fe97ec71775deb1f3078c6db0cb8db554bc6b76f /libbb/procps.c | |
parent | 988a78c61cffe91b005d37f0b7d6e2cb2c5ea713 (diff) |
A patch from Takeharu KATO to update/fix SE-Linux support.
Diffstat (limited to 'libbb/procps.c')
-rw-r--r-- | libbb/procps.c | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/libbb/procps.c b/libbb/procps.c index e405fb7ef..72f627f15 100644 --- a/libbb/procps.c +++ b/libbb/procps.c @@ -16,11 +16,7 @@ #include "libbb.h" -extern procps_status_t * procps_scan(int save_user_arg0 -#ifdef CONFIG_SELINUX - , int use_selinux , security_id_t *sid -#endif - ) +extern procps_status_t * procps_scan(int save_user_arg0) { static DIR *dir; struct dirent *entry; @@ -60,16 +56,9 @@ extern procps_status_t * procps_scan(int save_user_arg0 my_getpwuid(curstatus.user, sb.st_uid, sizeof(curstatus.user)); sprintf(status, "/proc/%d/stat", pid); + if((fp = fopen(status, "r")) == NULL) continue; -#ifdef CONFIG_SELINUX - if(use_selinux) - { - if(fstat_secure(fileno(fp), &sb, sid)) - continue; - } - else -#endif name = fgets(buf, sizeof(buf), fp); fclose(fp); if(name == NULL) |