Respect locale settings from the environment.

This commit is contained in:
tjr 2004-07-11 14:44:23 +00:00
parent 87af04ca9a
commit 53407e8087

View File

@ -52,6 +52,7 @@ static const char sccsid[] = "@(#)split.c 8.2 (Berkeley) 4/16/94";
#include <fcntl.h>
#include <inttypes.h>
#include <limits.h>
#include <locale.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
@ -85,6 +86,8 @@ main(int argc, char **argv)
int ch;
char *ep, *p;
setlocale(LC_ALL, "");
while ((ch = getopt(argc, argv, "-0123456789a:b:l:p:")) != -1)
switch (ch) {
case '0': case '1': case '2': case '3': case '4':