Module Name: src Committed By: rillig Date: Tue Dec 14 00:45:11 UTC 2021
Modified Files: src/usr.bin/make: parse.c Log Message: make: remove dead code for handling traditional include directives This code is not reached, a line containing only the word "include" is categorized as error before. No functional change. To generate a diff of this commit: cvs rdiff -u -r1.579 -r1.580 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.579 src/usr.bin/make/parse.c:1.580 --- src/usr.bin/make/parse.c:1.579 Tue Dec 14 00:17:53 2021 +++ src/usr.bin/make/parse.c Tue Dec 14 00:45:11 2021 @@ -1,4 +1,4 @@ -/* $NetBSD: parse.c,v 1.579 2021/12/14 00:17:53 rillig Exp $ */ +/* $NetBSD: parse.c,v 1.580 2021/12/14 00:45:11 rillig Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1993 @@ -109,7 +109,7 @@ #include "pathnames.h" /* "@(#)parse.c 8.3 (Berkeley) 3/19/94" */ -MAKE_RCSID("$NetBSD: parse.c,v 1.579 2021/12/14 00:17:53 rillig Exp $"); +MAKE_RCSID("$NetBSD: parse.c,v 1.580 2021/12/14 00:45:11 rillig Exp $"); /* types and constants */ @@ -2477,18 +2477,9 @@ ParseTraditionalInclude(char *line) pp_skip_whitespace(&file); - /* - * Substitute for any variables in the file name before trying to - * find the thing. - */ (void)Var_Subst(file, SCOPE_CMDLINE, VARE_WANTRES, &all_files); /* TODO: handle errors */ - if (*file == '\0') { - Parse_Error(PARSE_FATAL, "Filename missing from \"include\""); - goto out; - } - for (file = all_files; !done; file = cp + 1) { /* Skip to end of line or next whitespace */ for (cp = file; *cp != '\0' && !ch_isspace(*cp); cp++) @@ -2501,7 +2492,7 @@ ParseTraditionalInclude(char *line) IncludeFile(file, false, false, silent); } -out: + free(all_files); } #endif