Get rid of using deprecated function isascii
authorDmitry Belyavskiy <beldmit@gmail.com>
Sun, 18 Aug 2019 08:29:50 +0000 (11:29 +0300)
committerDmitry Belyavskiy <beldmit@gmail.com>
Mon, 19 Aug 2019 17:52:25 +0000 (20:52 +0300)
Avoid using functions deprecated in some libcs (e.g. uClibc-ng).
Fixes #9557

Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de>
Reviewed-by: Paul Dale <paul.dale@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/9628)

apps/s_server.c

index 3ded4f88cc16ee8807b08d82b8fa148325b585b1..28937bd80f49e1178782c89a274852435e887731 100644 (file)
@@ -470,7 +470,7 @@ static int ssl_servername_cb(SSL *s, int *ad, void *arg)
         BIO_printf(p->biodebug, "Hostname in TLS extension: \"");
         while ((uc = *cp++) != 0)
             BIO_printf(p->biodebug,
         BIO_printf(p->biodebug, "Hostname in TLS extension: \"");
         while ((uc = *cp++) != 0)
             BIO_printf(p->biodebug,
-                       isascii(uc) && isprint(uc) ? "%c" : "\\x%02x", uc);
+                       (((uc) & ~127) == 0) && isprint(uc) ? "%c" : "\\x%02x", uc);
         BIO_printf(p->biodebug, "\"\n");
     }
 
         BIO_printf(p->biodebug, "\"\n");
     }