diff options
author | Eric Andersen <andersen@codepoet.org> | 2001-06-26 23:11:44 +0000 |
---|---|---|
committer | Eric Andersen <andersen@codepoet.org> | 2001-06-26 23:11:44 +0000 |
commit | 0392b8638e7e75b7d5979143f812a9bf08ef501b (patch) | |
tree | 9848ad81c2b33a285be0ecba2b2d84663fe2b73e /procps/ps.c | |
parent | a90f20b1c330bef928e99031e710836024fcaf5f (diff) | |
download | busybox-w32-0392b8638e7e75b7d5979143f812a9bf08ef501b.tar.gz busybox-w32-0392b8638e7e75b7d5979143f812a9bf08ef501b.tar.bz2 busybox-w32-0392b8638e7e75b7d5979143f812a9bf08ef501b.zip |
Minor formatting change
Diffstat (limited to 'procps/ps.c')
-rw-r--r-- | procps/ps.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/procps/ps.c b/procps/ps.c index c59fc0f9c..7afb0091f 100644 --- a/procps/ps.c +++ b/procps/ps.c | |||
@@ -132,7 +132,7 @@ extern int ps_main(int argc, char **argv) | |||
132 | terminal_width = win.ws_col - 1; | 132 | terminal_width = win.ws_col - 1; |
133 | #endif | 133 | #endif |
134 | 134 | ||
135 | printf("%5s %-8s %5s %s\n", "PID", "Uid", "State", "Command"); | 135 | printf(" PID Uid Stat Command\n"); |
136 | while ((entry = readdir(dir)) != NULL) { | 136 | while ((entry = readdir(dir)) != NULL) { |
137 | if (!isdigit(*entry->d_name)) | 137 | if (!isdigit(*entry->d_name)) |
138 | continue; | 138 | continue; |
@@ -151,7 +151,7 @@ extern int ps_main(int argc, char **argv) | |||
151 | if (file == NULL) | 151 | if (file == NULL) |
152 | continue; | 152 | continue; |
153 | i = 0; | 153 | i = 0; |
154 | len = printf("%5d %-8s %c ", p.pid, uidName, p.state); | 154 | len = printf("%5d %-8s %c ", p.pid, uidName, p.state); |
155 | while (((c = getc(file)) != EOF) && (i < (terminal_width-len))) { | 155 | while (((c = getc(file)) != EOF) && (i < (terminal_width-len))) { |
156 | i++; | 156 | i++; |
157 | if (c == '\0') | 157 | if (c == '\0') |
@@ -223,7 +223,7 @@ extern int ps_main(int argc, char **argv) | |||
223 | #endif | 223 | #endif |
224 | 224 | ||
225 | /* Print up a ps listing */ | 225 | /* Print up a ps listing */ |
226 | printf("%5s %-8s %5s %s\n", "PID", "Uid", "State", "Command"); | 226 | printf(" PID Uid Stat Command\n"); |
227 | 227 | ||
228 | for (i=1; i<pid_array[0] ; i++) { | 228 | for (i=1; i<pid_array[0] ; i++) { |
229 | info.pid = pid_array[i]; | 229 | info.pid = pid_array[i]; |
@@ -236,7 +236,7 @@ extern int ps_main(int argc, char **argv) | |||
236 | if (*uidName == '\0') | 236 | if (*uidName == '\0') |
237 | sprintf(uidName, "%ld", info.euid); | 237 | sprintf(uidName, "%ld", info.euid); |
238 | 238 | ||
239 | len = printf("%5d %-8s %c ", info.pid, uidName, info.state); | 239 | len = printf("%5d %-8s %c ", info.pid, uidName, info.state); |
240 | 240 | ||
241 | if (strlen(info.command_line) > 1) { | 241 | if (strlen(info.command_line) > 1) { |
242 | for( j=0; j<(sizeof(info.command_line)-1) && j < (terminal_width-len); j++) { | 242 | for( j=0; j<(sizeof(info.command_line)-1) && j < (terminal_width-len); j++) { |