Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/crypto/dist/ipsec-tools/src/libipsec libipsec: fix undefined...
details: https://anonhg.NetBSD.org/src/rev/7d1c8d7d2609
branches: trunk
changeset: 1023414:7d1c8d7d2609
user: rillig <rillig%NetBSD.org@localhost>
date: Mon Sep 06 17:19:52 2021 +0000
description:
libipsec: fix undefined behavior when calling isprint
diffstat:
crypto/dist/ipsec-tools/src/libipsec/key_debug.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diffs (18 lines):
diff -r 71cf34bf43b8 -r 7d1c8d7d2609 crypto/dist/ipsec-tools/src/libipsec/key_debug.c
--- a/crypto/dist/ipsec-tools/src/libipsec/key_debug.c Mon Sep 06 15:17:25 2021 +0000
+++ b/crypto/dist/ipsec-tools/src/libipsec/key_debug.c Mon Sep 06 17:19:52 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: key_debug.c,v 1.15 2020/06/05 15:19:08 christos Exp $ */
+/* $NetBSD: key_debug.c,v 1.16 2021/09/06 17:19:52 rillig Exp $ */
/* $KAME: key_debug.c,v 1.29 2001/08/16 14:25:41 itojun Exp $ */
@@ -299,7 +299,7 @@
p = (void *)(id + 1);
ep = p + len;
for (/*nothing*/; *p && p < ep; p++) {
- if (isprint((int)*p))
+ if (isprint((unsigned char)*p))
printf("%c", *p & 0xff);
else
printf("\\%03o", *p & 0xff);
Home |
Main Index |
Thread Index |
Old Index