summaryrefslogtreecommitdiff
path: root/coreutils/od.c
diff options
context:
space:
mode:
authorEric Andersen2006-01-30 19:48:23 +0000
committerEric Andersen2006-01-30 19:48:23 +0000
commit5e678873f9ff7c95d43b278feee547ce989b3b20 (patch)
tree6b0bab1e0d6df7f659352acc7dc844663c11634c /coreutils/od.c
parent2cdd4d56ffc3b467d5ffa76e3c4cd009dc311097 (diff)
downloadbusybox-5e678873f9ff7c95d43b278feee547ce989b3b20.zip
busybox-5e678873f9ff7c95d43b278feee547ce989b3b20.tar.gz
clean up yet more annoying signed/unsigned mismatches and fixup
yet more incorrect types
Diffstat (limited to 'coreutils/od.c')
-rw-r--r--coreutils/od.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/coreutils/od.c b/coreutils/od.c
index 6a138e8..b70cb85 100644
--- a/coreutils/od.c
+++ b/coreutils/od.c
@@ -155,9 +155,9 @@ static const char * const add_strings[] = {
"4/4 \" %011o \" \"\\n\"", /* O */
};
-static const signed char od_opts[] = "aBbcDdeFfHhIiLlOoXxv";
+static const char od_opts[] = "aBbcDdeFfHhIiLlOoXxv";
-static const signed char od_o2si[] = {
+static const char od_o2si[] = {
0, 1, 2, 3, 5,
4, 6, 6, 7, 8,
9, 0xa, 0xb, 0xa, 0xa,
@@ -168,14 +168,14 @@ int od_main(int argc, char **argv)
{
int ch;
int first = 1;
- signed char *p;
+ char *p;
bb_dump_vflag = FIRST;
bb_dump_length = -1;
while ((ch = getopt(argc, argv, od_opts)) > 0) {
if (ch == 'v') {
bb_dump_vflag = ALL;
- } else if (((p = strchr(od_opts, ch)) != NULL) && (*p >= 0)) {
+ } else if (((p = strchr(od_opts, ch)) != NULL) && (*p != '\0')) {
if (first) {
first = 0;
bb_dump_add("\"%07.7_Ao\n\"");
@@ -183,7 +183,7 @@ int od_main(int argc, char **argv)
} else {
bb_dump_add("\" \"");
}
- bb_dump_add(add_strings[od_o2si[(int)(p-od_opts)]]);
+ bb_dump_add(add_strings[(int)od_o2si[(p-od_opts)]]);
} else { /* P, p, s, w, or other unhandled */
bb_show_usage();
}