aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2010-06-18 14:09:48 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2010-06-18 14:09:48 +0200
commit1ed2fb40c919a25fe6920680cf898d0b4870c60e (patch)
tree15b1a1ead018ee29f144bc8bf3de77d9c170dd17
parentb76f18d331f865225f1702794e66e87818584f99 (diff)
downloadbusybox-w32-1ed2fb40c919a25fe6920680cf898d0b4870c60e.tar.gz
busybox-w32-1ed2fb40c919a25fe6920680cf898d0b4870c60e.tar.bz2
busybox-w32-1ed2fb40c919a25fe6920680cf898d0b4870c60e.zip
ash: cosmetics, no code changes
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--shell/ash.c30
1 files changed, 7 insertions, 23 deletions
diff --git a/shell/ash.c b/shell/ash.c
index 90680e849..fcaa7b18e 100644
--- a/shell/ash.c
+++ b/shell/ash.c
@@ -46,6 +46,7 @@
46#include <paths.h> 46#include <paths.h>
47#include <setjmp.h> 47#include <setjmp.h>
48#include <fnmatch.h> 48#include <fnmatch.h>
49#include <sys/times.h>
49 50
50#include "shell_common.h" 51#include "shell_common.h"
51#include "math.h" 52#include "math.h"
@@ -7310,7 +7311,7 @@ shellexec(char **argv, const char *path, int idx)
7310#endif 7311#endif
7311 7312
7312 clearredir(/*drop:*/ 1); 7313 clearredir(/*drop:*/ 1);
7313 envp = listvars(VEXPORT, VUNSET, 0); 7314 envp = listvars(VEXPORT, VUNSET, /*end:*/ NULL);
7314 if (strchr(argv[0], '/') != NULL 7315 if (strchr(argv[0], '/') != NULL
7315#if ENABLE_FEATURE_SH_STANDALONE 7316#if ENABLE_FEATURE_SH_STANDALONE
7316 || (applet_no = find_applet_by_name(argv[0])) >= 0 7317 || (applet_no = find_applet_by_name(argv[0])) >= 0
@@ -12468,7 +12469,7 @@ unsetfunc(const char *name)
12468 struct tblentry *cmdp; 12469 struct tblentry *cmdp;
12469 12470
12470 cmdp = cmdlookup(name, 0); 12471 cmdp = cmdlookup(name, 0);
12471 if (cmdp!= NULL && cmdp->cmdtype == CMDFUNCTION) 12472 if (cmdp != NULL && cmdp->cmdtype == CMDFUNCTION)
12472 delete_cmd_entry(); 12473 delete_cmd_entry();
12473} 12474}
12474 12475
@@ -12485,7 +12486,7 @@ unsetcmd(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
12485 int flag = 0; 12486 int flag = 0;
12486 int ret = 0; 12487 int ret = 0;
12487 12488
12488 while ((i = nextopt("vf")) != '\0') { 12489 while ((i = nextopt("vf")) != 0) {
12489 flag = i; 12490 flag = i;
12490 } 12491 }
12491 12492
@@ -12502,11 +12503,6 @@ unsetcmd(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
12502 return ret & 1; 12503 return ret & 1;
12503} 12504}
12504 12505
12505
12506/* setmode.c */
12507
12508#include <sys/times.h>
12509
12510static const unsigned char timescmd_str[] ALIGN1 = { 12506static const unsigned char timescmd_str[] ALIGN1 = {
12511 ' ', offsetof(struct tms, tms_utime), 12507 ' ', offsetof(struct tms, tms_utime),
12512 '\n', offsetof(struct tms, tms_stime), 12508 '\n', offsetof(struct tms, tms_stime),
@@ -12514,7 +12510,6 @@ static const unsigned char timescmd_str[] ALIGN1 = {
12514 '\n', offsetof(struct tms, tms_cstime), 12510 '\n', offsetof(struct tms, tms_cstime),
12515 0 12511 0
12516}; 12512};
12517
12518static int FAST_FUNC 12513static int FAST_FUNC
12519timescmd(int argc UNUSED_PARAM, char **argv UNUSED_PARAM) 12514timescmd(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
12520{ 12515{
@@ -12533,14 +12528,15 @@ timescmd(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
12533 s/60, s%60, 12528 s/60, s%60,
12534 ((t - s * clk_tck) * 1000) / clk_tck, 12529 ((t - s * clk_tck) * 1000) / clk_tck,
12535 p[0]); 12530 p[0]);
12536 } while (*(p += 2)); 12531 p += 2;
12532 } while (*p);
12537 12533
12538 return 0; 12534 return 0;
12539} 12535}
12540 12536
12541#if ENABLE_SH_MATH_SUPPORT 12537#if ENABLE_SH_MATH_SUPPORT
12542/* 12538/*
12543 * The let builtin. partial stolen from GNU Bash, the Bourne Again SHell. 12539 * The let builtin. Partially stolen from GNU Bash, the Bourne Again SHell.
12544 * Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc. 12540 * Copyright (C) 1987, 1989, 1991 Free Software Foundation, Inc.
12545 * 12541 *
12546 * Copyright (C) 2003 Vladimir Oleynik <dzo@simtreas.ru> 12542 * Copyright (C) 2003 Vladimir Oleynik <dzo@simtreas.ru>
@@ -12559,18 +12555,6 @@ letcmd(int argc UNUSED_PARAM, char **argv)
12559 12555
12560 return !i; 12556 return !i;
12561} 12557}
12562#endif /* SH_MATH_SUPPORT */
12563
12564
12565/* ============ miscbltin.c
12566 *
12567 * Miscellaneous builtins.
12568 */
12569
12570#undef rflag
12571
12572#if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ < 1
12573typedef enum __rlimit_resource rlim_t;
12574#endif 12558#endif
12575 12559
12576/* 12560/*