From 6f6d788e47f40e2d1059468c0a1c8b74d3054ee2 Mon Sep 17 00:00:00 2001 From: Theo de Raadt Date: Mon, 11 May 1998 01:19:18 +0000 Subject: set max field width of %s correctly --- usr.sbin/config/mkheaders.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'usr.sbin/config/mkheaders.c') diff --git a/usr.sbin/config/mkheaders.c b/usr.sbin/config/mkheaders.c index 583c2556418..92870708cde 100644 --- a/usr.sbin/config/mkheaders.c +++ b/usr.sbin/config/mkheaders.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mkheaders.c,v 1.8 1997/08/07 10:36:58 deraadt Exp $ */ +/* $OpenBSD: mkheaders.c,v 1.9 1998/05/11 01:19:17 deraadt Exp $ */ /* $NetBSD: mkheaders.c,v 1.12 1997/02/02 21:12:34 thorpej Exp $ */ /* @@ -100,7 +100,7 @@ emitcnt(head) while (fgets(buf, sizeof(buf), fp) != NULL) { if (nv == NULL) goto writeit; - if (sscanf(buf, "#define %s %d", nam, &cnt) != 2 || + if (sscanf(buf, "#define %100s %d", nam, &cnt) != 2 || strcmp(nam, cntname(nv->nv_name)) != 0 || cnt != nv->nv_int) goto writeit; -- cgit v1.2.3