summaryrefslogtreecommitdiff
path: root/devel/cscope/patches/patch-ao
blob: 7ff7668f17fe1ae56807a39cd2544c7d76040c8b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
$NetBSD: patch-ao,v 1.2 2006/05/29 13:51:20 tron Exp $

--- src/vpopen.c.orig	2002-07-29 13:37:50.000000000 +0100
+++ src/vpopen.c	2006-05-29 14:34:26.000000000 +0100
@@ -52,7 +52,7 @@
 	    oflag == OPENFLAG_READ) {
 		vpinit(NULL);
 		for (i = 1; i < vpndirs; i++) {
-			(void) sprintf(buf, "%s/%s", vpdirs[i], path);
+			(void) snprintf(buf, sizeof(buf), "%s/%s", vpdirs[i], path);
 			if ((returncode = myopen(buf, oflag, 0666)) != -1) {
 				break;
 			}