From 2a993c7e5c3faf3a8490173cd444e2c0cfb9e929 Mon Sep 17 00:00:00 2001 From: bitblt Date: Tue, 4 Mar 1997 16:32:37 +0000 Subject: sprintf -> snprintf paranoia --- lib/libwrap/options.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/libwrap/options.c b/lib/libwrap/options.c index 30e456f3887..411cf72b2ef 100644 --- a/lib/libwrap/options.c +++ b/lib/libwrap/options.c @@ -1,4 +1,4 @@ -/* $OpenBSD: options.c,v 1.1 1997/02/26 03:06:54 downsj Exp $ */ +/* $OpenBSD: options.c,v 1.2 1997/03/04 16:32:36 bitblt Exp $ */ /* * General skeleton for adding options to the access control language. The @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#) options.c 1.17 96/02/11 17:01:31"; #else -static char rcsid[] = "$OpenBSD: options.c,v 1.1 1997/02/26 03:06:54 downsj Exp $"; +static char rcsid[] = "$OpenBSD: options.c,v 1.2 1997/03/04 16:32:36 bitblt Exp $"; #endif #endif @@ -232,7 +232,7 @@ struct request_info *request; int ch; FILE *fp; - sprintf(path, "%s/%s", value, eval_daemon(request)); + snprintf(path, sizeof (path), "%s/%s", value, eval_daemon(request)); if ((fp = fopen(path, "r")) != 0) { while ((ch = fgetc(fp)) == 0) write(request->fd, "", 1); -- cgit v1.2.3