summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormillert <millert@openbsd.org>2001-08-18 20:34:38 +0000
committermillert <millert@openbsd.org>2001-08-18 20:34:38 +0000
commit20ad59807fc3526d118465bd5318f79d29de41ed (patch)
tree148e8b8b0f633949fcd1c7d9dab0122469dea281
parentWe don't provide COMPAT_1[234] options anymore. (diff)
downloadwireguard-openbsd-20ad59807fc3526d118465bd5318f79d29de41ed.tar.xz
wireguard-openbsd-20ad59807fc3526d118465bd5318f79d29de41ed.zip
Fix a pasto I made when adding snprintf() return val checks ages ago.
-rw-r--r--usr.bin/vi/common/api.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/vi/common/api.c b/usr.bin/vi/common/api.c
index 3cb31f88911..6f678d17f97 100644
--- a/usr.bin/vi/common/api.c
+++ b/usr.bin/vi/common/api.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: api.c,v 1.9 2001/01/29 01:58:28 niklas Exp $ */
+/* $OpenBSD: api.c,v 1.10 2001/08/18 20:34:38 millert Exp $ */
/*-
* Copyright (c) 1992, 1993, 1994
@@ -502,8 +502,8 @@ api_opts_set(sp, name, str_value, num_value, bool_value)
case OPT_STR:
GET_SPACE_RET(sp, bp, blen, 1024);
a.len = snprintf(bp, 1024, "%s=%s", name, str_value);
- if (a.len > 63)
- a.len = 63;
+ if (a.len > 1023)
+ a.len = 1023;
break;
}
a.bp = bp;