diff options
author | ache <ache@FreeBSD.org> | 1996-08-12 18:56:38 +0000 |
---|---|---|
committer | ache <ache@FreeBSD.org> | 1996-08-12 18:56:38 +0000 |
commit | ffcd81205d69b9483f54a151cb05bd31e5bb190c (patch) | |
tree | 9d46ef220b6027b77510be74cc8b6a0b7290c4f1 /lib/libcompat/regexp | |
parent | 18e6a0b58f4135d736969d9e1db05995eb4ac5f5 (diff) | |
download | FreeBSD-src-ffcd81205d69b9483f54a151cb05bd31e5bb190c.zip FreeBSD-src-ffcd81205d69b9483f54a151cb05bd31e5bb190c.tar.gz |
Convert to newly aded collate compare function
Diffstat (limited to 'lib/libcompat/regexp')
-rw-r--r-- | lib/libcompat/regexp/regexp.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/libcompat/regexp/regexp.c b/lib/libcompat/regexp/regexp.c index 8bfa3ca..963d6ab 100644 --- a/lib/libcompat/regexp/regexp.c +++ b/lib/libcompat/regexp/regexp.c @@ -32,13 +32,14 @@ * precedence is structured in regular expressions. Serious changes in * regular-expression syntax might require a total rethink. */ +#include <limits.h> +#include <locale.h> #include <regexp.h> #include <stdio.h> #include <ctype.h> #include <stdlib.h> #include <string.h> #include "regmagic.h" -#include "collate.h" /* * The "internal use only" fields in regexp.h are present to pass info from @@ -507,12 +508,12 @@ int *flagp; else { class = UCHARAT(regparse-2); classend = UCHARAT(regparse); - if (__collcmp(class, classend) > 0) + if (collate_range_cmp(class, classend) > 0) FAIL("invalid [] range"); for (i = 0; i <= UCHAR_MAX; i++) if ( i != class - && __collcmp(class, i) <= 0 - && __collcmp(i, classend) <= 0 + && collate_range_cmp(class, i) <= 0 + && collate_range_cmp(i, classend) <= 0 ) regc(i); regparse++; |