=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/cvs/root.c,v retrieving revision 1.47 retrieving revision 1.48 diff -u -r1.47 -r1.48 --- src/usr.bin/cvs/root.c 2010/10/23 18:36:35 1.47 +++ src/usr.bin/cvs/root.c 2015/01/16 06:40:07 1.48 @@ -1,4 +1,4 @@ -/* $OpenBSD: root.c,v 1.47 2010/10/23 18:36:35 nicm Exp $ */ +/* $OpenBSD: root.c,v 1.48 2015/01/16 06:40:07 deraadt Exp $ */ /* * Copyright (c) 2004 Jean-Francois Brousseau * All rights reserved. @@ -163,7 +163,7 @@ struct cvsroot * cvsroot_get(const char *dir) { - char rootpath[MAXPATHLEN], *rootstr, line[128]; + char rootpath[PATH_MAX], *rootstr, line[128]; FILE *fp; if (cvs_rootstr != NULL) @@ -178,7 +178,7 @@ return (NULL); } - (void)xsnprintf(rootpath, MAXPATHLEN, "%s/%s", dir, CVS_PATH_ROOTSPEC); + (void)xsnprintf(rootpath, PATH_MAX, "%s/%s", dir, CVS_PATH_ROOTSPEC); if ((fp = fopen(rootpath, "r")) == NULL) { if (errno == ENOENT) {