From 3bd90e16be42e3493ed6bbbe42ba08bc9c8a2005 Mon Sep 17 00:00:00 2001 From: ache Date: Thu, 31 Oct 1996 07:15:57 +0000 Subject: 1) define STATIC as static and not empty 2) replace collate_range_cmp call with its code --- bin/sh/expand.c | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) (limited to 'bin/sh/expand.c') diff --git a/bin/sh/expand.c b/bin/sh/expand.c index ff34da7..659da14 100644 --- a/bin/sh/expand.c +++ b/bin/sh/expand.c @@ -33,7 +33,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id$ + * $Id: expand.c,v 1.10 1996/09/10 02:42:30 peter Exp $ */ #ifndef lint @@ -48,7 +48,7 @@ static char sccsid[] = "@(#)expand.c 8.5 (Berkeley) 5/15/95"; #include #include #include -#include +#include /* * Routines to expand arguments to commands. We have to deal with @@ -108,6 +108,24 @@ STATIC struct strlist *expsort __P((struct strlist *)); STATIC struct strlist *msort __P((struct strlist *, int)); STATIC int pmatch __P((char *, char *)); STATIC char *cvtnum __P((int, char *)); +STATIC int collate_range_cmp __P((int, int)); + +STATIC int collate_range_cmp (c1, c2) + int c1, c2; +{ + static char s1[2], s2[2]; + int ret; + + c1 &= UCHAR_MAX; + c2 &= UCHAR_MAX; + if (c1 == c2) + return (0); + s1[0] = c1; + s2[0] = c2; + if ((ret = strcoll(s1, s2)) != 0) + return (ret); + return (c1 - c2); +} /* * Expand shell variables and backquotes inside a here document. -- cgit v1.1