Module Name: src
Committed By: rillig
Date: Sat Dec 19 00:02:35 UTC 2020
Modified Files:
src/usr.bin/make: parse.c
Log Message:
make(1): clean up another local variable in ParseGetLine
To generate a diff of this commit:
cvs rdiff -u -r1.487 -r1.488 src/usr.bin/make/parse.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/usr.bin/make/parse.c
diff -u src/usr.bin/make/parse.c:1.487 src/usr.bin/make/parse.c:1.488
--- src/usr.bin/make/parse.c:1.487 Fri Dec 18 23:18:08 2020
+++ src/usr.bin/make/parse.c Sat Dec 19 00:02:34 2020
@@ -1,4 +1,4 @@
-/* $NetBSD: parse.c,v 1.487 2020/12/18 23:18:08 rillig Exp $ */
+/* $NetBSD: parse.c,v 1.488 2020/12/19 00:02:34 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@@ -117,7 +117,7 @@
#include "pathnames.h"
/* "@(#)parse.c 8.3 (Berkeley) 3/19/94" */
-MAKE_RCSID("$NetBSD: parse.c,v 1.487 2020/12/18 23:18:08 rillig Exp $");
+MAKE_RCSID("$NetBSD: parse.c,v 1.488 2020/12/19 00:02:34 rillig Exp $");
/* types and constants */
@@ -2657,7 +2657,7 @@ ParseEOF(void)
}
static void
-UnescapeBackslash(char **out_tp, char *escaped, char *const line)
+UnescapeBackslash(char *escaped, char *const line)
{
char *tp, *ptr;
@@ -2710,8 +2710,6 @@ UnescapeBackslash(char **out_tp, char *e
while (tp > escaped && ch_isspace(tp[-1]))
tp--;
*tp = '\0';
-
- *out_tp = tp;
}
typedef enum GetLineMode {
@@ -2730,7 +2728,6 @@ ParseGetLine(GetLineMode mode)
char *line_end;
char *escaped;
char *comment;
- char *tp;
/* Loop through blank lines and comment lines */
for (;;) {
@@ -2831,7 +2828,7 @@ ParseGetLine(GetLineMode mode)
return line;
/* Remove escapes from '\n' and '#' */
- UnescapeBackslash(&tp, escaped, line);
+ UnescapeBackslash(escaped, line);
return line;
}