Ensure buf2 is in scope

This commit is contained in:
Simon J. Gerraty 2017-05-10 22:24:09 +00:00
parent ddae57504b
commit e23f3f6ec0
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=318161

View file

@ -751,6 +751,7 @@ Main_SetObjdir(const char *fmt, ...)
struct stat sb;
char *path;
char buf[MAXPATHLEN + 1];
char buf2[MAXPATHLEN + 1];
Boolean rc = FALSE;
va_list ap;
@ -759,8 +760,6 @@ Main_SetObjdir(const char *fmt, ...)
va_end(ap);
if (path[0] != '/') {
char buf2[MAXPATHLEN + 1];
snprintf(buf2, MAXPATHLEN, "%s/%s", curdir, path);
path = buf2;
}