diff options
author | Glenn L McGrath <bug1@ihug.co.nz> | 2003-12-19 10:13:10 +0000 |
---|---|---|
committer | Glenn L McGrath <bug1@ihug.co.nz> | 2003-12-19 10:13:10 +0000 |
commit | 850b05fbde26981347dbc522592d33530e9009bd (patch) | |
tree | 0fa1bae60686d1ad8522e003442385f8ccaf8483 | |
parent | f796700cf010d7ff2615c59bc364bbbef14153a4 (diff) | |
download | busybox-w32-850b05fbde26981347dbc522592d33530e9009bd.tar.gz busybox-w32-850b05fbde26981347dbc522592d33530e9009bd.tar.bz2 busybox-w32-850b05fbde26981347dbc522592d33530e9009bd.zip |
Fix a bug preventing use of escaped characters that use the signed bit
-rw-r--r-- | libbb/getopt_ulflags.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/libbb/getopt_ulflags.c b/libbb/getopt_ulflags.c index 04d1e669f..371fdab26 100644 --- a/libbb/getopt_ulflags.c +++ b/libbb/getopt_ulflags.c | |||
@@ -60,7 +60,7 @@ const char *bb_opt_complementaly; | |||
60 | 60 | ||
61 | typedef struct | 61 | typedef struct |
62 | { | 62 | { |
63 | char opt; | 63 | unsigned char opt; |
64 | char list_flg; | 64 | char list_flg; |
65 | unsigned long switch_on; | 65 | unsigned long switch_on; |
66 | unsigned long switch_off; | 66 | unsigned long switch_off; |
@@ -159,10 +159,9 @@ bb_getopt_ulflags (int argc, char **argv, const char *applet_opts, ...) | |||
159 | 159 | ||
160 | while ((c = getopt_long (argc, argv, applet_opts, | 160 | while ((c = getopt_long (argc, argv, applet_opts, |
161 | bb_applet_long_options, NULL)) > 0) { | 161 | bb_applet_long_options, NULL)) > 0) { |
162 | |||
163 | for (on_off = complementaly; on_off->opt != c; on_off++) { | 162 | for (on_off = complementaly; on_off->opt != c; on_off++) { |
164 | if(!on_off->opt) | 163 | if(!on_off->opt) |
165 | bb_show_usage (); | 164 | bb_show_usage (); |
166 | } | 165 | } |
167 | if(flags & on_off->incongruously) | 166 | if(flags & on_off->incongruously) |
168 | flags |= 0x80000000UL; | 167 | flags |= 0x80000000UL; |