diff options
author | mjn3 <mjn3@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2002-03-25 02:37:20 +0000 |
---|---|---|
committer | mjn3 <mjn3@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2002-03-25 02:37:20 +0000 |
commit | 05044ea46d58f4c85095c4ebe9299f412d6bb11c (patch) | |
tree | 3dc3c890ed2bc1b14143272e556320fdeb56e091 | |
parent | 578e662918f44dbf45ff3e898a9983c3361fee2b (diff) | |
download | busybox-w32-05044ea46d58f4c85095c4ebe9299f412d6bb11c.tar.gz busybox-w32-05044ea46d58f4c85095c4ebe9299f412d6bb11c.tar.bz2 busybox-w32-05044ea46d58f4c85095c4ebe9299f412d6bb11c.zip |
Work around compiler/assembler problem and reduce code size at the same time.
git-svn-id: svn://busybox.net/trunk/busybox@4485 69ca8d6d-28ef-0310-b511-8ec308f3f277
-rw-r--r-- | coreutils/uname.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/coreutils/uname.c b/coreutils/uname.c index b45f4d156..df4f14ea0 100644 --- a/coreutils/uname.c +++ b/coreutils/uname.c | |||
@@ -87,7 +87,7 @@ int uname_main(int argc, char **argv) | |||
87 | } | 87 | } |
88 | 88 | ||
89 | #if defined(__sparc__) && defined(__linux__) | 89 | #if defined(__sparc__) && defined(__linux__) |
90 | if ((fake_sparc != NULL) | 90 | if ((fake_sparc != NULL) |
91 | && ((fake_sparc[0] == 'y') | 91 | && ((fake_sparc[0] == 'y') |
92 | || (fake_sparc[0] == 'Y'))) { | 92 | || (fake_sparc[0] == 'Y'))) { |
93 | strcpy(uname_info.name.machine, "sparc"); | 93 | strcpy(uname_info.name.machine, "sparc"); |
@@ -96,11 +96,16 @@ int uname_main(int argc, char **argv) | |||
96 | 96 | ||
97 | strcpy(uname_info.processor, "unknown"); | 97 | strcpy(uname_info.processor, "unknown"); |
98 | 98 | ||
99 | for (opt=0,delta=utsname_offset ; toprint ; delta++, toprint >>= 1) { | 99 | delta=utsname_offset; |
100 | do { | ||
100 | if (toprint & 1) { | 101 | if (toprint & 1) { |
101 | printf("%s%s", (opt++==0)? "": " ", ((char *)(&uname_info)) + *delta); | 102 | printf(((char *)(&uname_info)) + *delta); |
103 | if (toprint > 1) { | ||
104 | putchar(' '); | ||
105 | } | ||
102 | } | 106 | } |
103 | } | 107 | ++delta; |
108 | } while (toprint >>= 1); | ||
104 | putchar('\n'); | 109 | putchar('\n'); |
105 | 110 | ||
106 | return EXIT_SUCCESS; | 111 | return EXIT_SUCCESS; |