Add setlocale LC_CTYPE

Fix icase searches for 8bit charsets
This commit is contained in:
ache 1995-10-28 19:16:14 +00:00
parent 575fa54d89
commit a8549c180a
2 changed files with 7 additions and 1 deletions

View File

@ -19,6 +19,9 @@
#include <errno.h>
#include <stdio.h>
#ifdef __FreeBSD__
#include <locale.h>
#endif
#ifndef errno
extern int errno;
@ -606,6 +609,9 @@ main(argc, argv)
extern char *optarg;
extern int optind;
#ifdef __FreeBSD__
(void) setlocale(LC_CTYPE, "");
#endif
prog = argv[0];
if (prog && strrchr(prog, '/'))
prog = strrchr(prog, '/') + 1;

View File

@ -46,7 +46,7 @@ extern char *memchr();
#define bcopy(s, d, n) memcpy((d), (s), (n))
#endif
#ifdef isascii
#if defined(isascii) && !defined(__FreeBSD__)
#define ISALNUM(C) (isascii(C) && isalnum(C))
#define ISUPPER(C) (isascii(C) && isupper(C))
#else