diff --git a/usr.bin/make/var.c b/usr.bin/make/var.c index 7753d9b5331c..ee2ba71dabcf 100644 --- a/usr.bin/make/var.c +++ b/usr.bin/make/var.c @@ -1,4 +1,4 @@ -/* $NetBSD: var.c,v 1.71 2003/03/14 05:19:43 thorpej Exp $ */ +/* $NetBSD: var.c,v 1.72 2003/05/22 18:20:10 christos Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1993 @@ -39,14 +39,14 @@ */ #ifdef MAKE_BOOTSTRAP -static char rcsid[] = "$NetBSD: var.c,v 1.71 2003/03/14 05:19:43 thorpej Exp $"; +static char rcsid[] = "$NetBSD: var.c,v 1.72 2003/05/22 18:20:10 christos Exp $"; #else #include #ifndef lint #if 0 static char sccsid[] = "@(#)var.c 8.3 (Berkeley) 3/19/94"; #else -__RCSID("$NetBSD: var.c,v 1.71 2003/03/14 05:19:43 thorpej Exp $"); +__RCSID("$NetBSD: var.c,v 1.72 2003/05/22 18:20:10 christos Exp $"); #endif #endif /* not lint */ #endif @@ -2010,7 +2010,7 @@ Var_Parse(char *str, GNode *ctxt, Boolean err, int *lengthPtr, * Skip initial colon while putting it back. */ *tstr++ = ':'; - while (*tstr != endc) { + while (*tstr && *tstr != endc) { char *newStr; /* New value to return */ char termc; /* Character which terminated scan */