diff options
Diffstat (limited to 'coreutils')
-rw-r--r-- | coreutils/seq.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/coreutils/seq.c b/coreutils/seq.c index bb39a5b54..03ae3c632 100644 --- a/coreutils/seq.c +++ b/coreutils/seq.c | |||
@@ -22,8 +22,15 @@ int seq_main(int argc, char **argv) | |||
22 | unsigned width; | 22 | unsigned width; |
23 | unsigned frac_part; | 23 | unsigned frac_part; |
24 | const char *sep, *opt_s = "\n"; | 24 | const char *sep, *opt_s = "\n"; |
25 | unsigned opt = getopt32(argv, "+ws:", &opt_s); | 25 | unsigned opt; |
26 | 26 | ||
27 | #if ENABLE_LOCALE_SUPPORT | ||
28 | /* Undo busybox.c: on input, we want to use dot | ||
29 | * as fractional separator, regardless of current locale */ | ||
30 | setlocale(LC_NUMERIC, "C"); | ||
31 | #endif | ||
32 | |||
33 | opt = getopt32(argv, "+ws:", &opt_s); | ||
27 | argc -= optind; | 34 | argc -= optind; |
28 | argv += optind; | 35 | argv += optind; |
29 | first = increment = 1; | 36 | first = increment = 1; |
@@ -44,6 +51,10 @@ int seq_main(int argc, char **argv) | |||
44 | bb_show_usage(); | 51 | bb_show_usage(); |
45 | } | 52 | } |
46 | 53 | ||
54 | #if ENABLE_LOCALE_SUPPORT | ||
55 | setlocale(LC_NUMERIC, ""); | ||
56 | #endif | ||
57 | |||
47 | /* Last checked to be compatible with: coreutils-6.10 */ | 58 | /* Last checked to be compatible with: coreutils-6.10 */ |
48 | width = 0; | 59 | width = 0; |
49 | frac_part = 0; | 60 | frac_part = 0; |