summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorMoritz Jodeit <moritz@cvs.openbsd.org>2005-04-28 10:12:59 +0000
committerMoritz Jodeit <moritz@cvs.openbsd.org>2005-04-28 10:12:59 +0000
commitc3ef1926e1cd5de5065948c171136b0cf36a0485 (patch)
tree523e1a469a29e8fccbc702b028de664cac53b0d9 /usr.sbin
parent0f345a5f1e841e2d61ba049644acd3b2edbb1720 (diff)
more vsnprintf checking. ok cloder@
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/bind/lib/isccfg/parser.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/bind/lib/isccfg/parser.c b/usr.sbin/bind/lib/isccfg/parser.c
index 76aa71625b0..3f84a95ff51 100644
--- a/usr.sbin/bind/lib/isccfg/parser.c
+++ b/usr.sbin/bind/lib/isccfg/parser.c
@@ -2117,7 +2117,7 @@ parser_complain(cfg_parser_t *pctx, isc_boolean_t is_warning,
current_file(pctx), pctx->line);
len = vsnprintf(message, sizeof(message), format, args);
- if (len >= sizeof(message))
+ if (len == -1 || len >= sizeof(message))
FATAL_ERROR(__FILE__, __LINE__,
"error message would overflow");