Loading...
gen/FreeBSD/vis.c Libc-825.25 Libc-763.12
--- Libc/Libc-825.25/gen/FreeBSD/vis.c
+++ Libc/Libc-763.12/gen/FreeBSD/vis.c
@@ -33,8 +33,6 @@
 #include <sys/cdefs.h>
 __FBSDID("$FreeBSD: src/lib/libc/gen/vis.c,v 1.14 2007/01/09 00:27:56 imp Exp $");
 
-#include "xlocale_private.h"
-
 #include <sys/types.h>
 #include <limits.h>
 #include <ctype.h>
@@ -52,20 +50,18 @@
 	int c, nextc;
 	int flag;
 {
-	locale_t loc = __current_locale();
-
 	c = (unsigned char)c;
 
 	if (flag & VIS_HTTPSTYLE) {
 		/* Described in RFC 1808 */
-		if (!(isalnum_l(c, loc) /* alpha-numeric */
+		if (!(isalnum(c) /* alpha-numeric */
 		    /* safe */
 		    || c == '$' || c == '-' || c == '_' || c == '.' || c == '+'
 		    /* extra */
 		    || c == '!' || c == '*' || c == '\'' || c == '('
 		    || c == ')' || c == ',')) {
 			*dst++ = '%';
-			snprintf_l(dst, 4, loc, (c < 16 ? "0%X" : "%X"), c);
+			snprintf(dst, 4, (c < 16 ? "0%X" : "%X"), c);
 			dst += 2;
 			goto done;
 		}
@@ -74,7 +70,7 @@
 	if ((flag & VIS_GLOB) &&
 	    (c == '*' || c == '?' || c == '[' || c == '#'))
 		;
-	else if (isgraph_l(c, loc) ||
+	else if (isgraph(c) ||
 	   ((flag & VIS_SP) == 0 && c == ' ') ||
 	   ((flag & VIS_TAB) == 0 && c == '\t') ||
 	   ((flag & VIS_NL) == 0 && c == '\n') ||
@@ -130,7 +126,7 @@
 			goto done;
 		}
 	}
-	if (((c & 0177) == ' ') || isgraph_l(c, loc) || (flag & VIS_OCTAL)) {
+	if (((c & 0177) == ' ') || isgraph(c) || (flag & VIS_OCTAL)) {
 		*dst++ = '\\';
 		*dst++ = ((u_char)c >> 6 & 07) + '0';
 		*dst++ = ((u_char)c >> 3 & 07) + '0';
@@ -143,7 +139,7 @@
 		c &= 0177;
 		*dst++ = 'M';
 	}
-	if (iscntrl_l(c, loc)) {
+	if (iscntrl(c)) {
 		*dst++ = '^';
 		if (c == 0177)
 			*dst++ = '?';