diff options
author | Bernhard Reutner-Fischer | 2006-05-29 12:10:23 +0000 |
---|---|---|
committer | Bernhard Reutner-Fischer | 2006-05-29 12:10:23 +0000 |
commit | d2c306e862abf49dd4b1ff1d1bd1a789317b7905 (patch) | |
tree | ea8e439001256f7f6da7683399115d009552d777 /coreutils/ls.c | |
parent | 1ec5b2905484b7904aabb01f56c70265fb538c82 (diff) | |
download | busybox-d2c306e862abf49dd4b1ff1d1bd1a789317b7905.zip busybox-d2c306e862abf49dd4b1ff1d1bd1a789317b7905.tar.gz |
- ls: remove unused variable
- dpkg.c, diff: use xstat
text data bss dec hex filename
848823 9100 645216 1503139 16efa3 busybox_old
848679 9100 645216 1502995 16ef13 busybox_unstripped
bloatcheck is completely useless as it sees -79 for this, which is bogus.
Diffstat (limited to 'coreutils/ls.c')
-rw-r--r-- | coreutils/ls.c | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/coreutils/ls.c b/coreutils/ls.c index 3fe0c8d..9c0e8f1 100644 --- a/coreutils/ls.c +++ b/coreutils/ls.c @@ -208,18 +208,15 @@ static struct dnode *my_stat(char *fullname, char *name) #ifdef CONFIG_SELINUX security_context_t sid=NULL; #endif - int rc; #ifdef CONFIG_FEATURE_LS_FOLLOWLINKS if (all_fmt & FOLLOW_LINKS) { #ifdef CONFIG_SELINUX - if (is_selinux_enabled()) { - rc=0; /* Set the number which means success before hand. */ - rc = getfilecon(fullname,&sid); + if (is_selinux_enabled()) { + getfilecon(fullname,&sid); } #endif - rc = stat(fullname, &dstat); - if(rc) { + if (stat(fullname, &dstat)) { bb_perror_msg("%s", fullname); status = EXIT_FAILURE; return 0; @@ -229,12 +226,10 @@ static struct dnode *my_stat(char *fullname, char *name) { #ifdef CONFIG_SELINUX if (is_selinux_enabled()) { - rc=0; /* Set the number which means success before hand. */ - rc = lgetfilecon(fullname,&sid); + lgetfilecon(fullname,&sid); } #endif - rc = lstat(fullname, &dstat); - if(rc) { + if (lstat(fullname, &dstat)) { bb_perror_msg("%s", fullname); status = EXIT_FAILURE; return 0; |