mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2024-12-23 01:53:46 +01:00
Make c89(1) invoke /usr/bin/cc with argv[0] also set to /usr/bin/cc,
similar to what c99(1) does, to prevent "c89: illegal option -- 1" messages, when clang is /usr/bin/cc. Reported by: tijl MFC after: 3 days
This commit is contained in:
parent
7f33ac6697
commit
b1bbb41f96
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=247951
@ -72,7 +72,7 @@ main(int argc, char **argv)
|
||||
Argv.a = malloc((argc + 1 + N_ARGS_PREPENDED) * sizeof *Argv.a);
|
||||
if (Argv.a == NULL)
|
||||
err(1, "malloc");
|
||||
Argv.a[Argc++] = argv[0];
|
||||
Argv.a[Argc++] = CC;
|
||||
for (j = 0; j < N_ARGS_PREPENDED; ++j)
|
||||
Argv.a[Argc++] = args_prepended[j];
|
||||
while ((i = getopt(argc, argv, "cD:EgI:l:L:o:OsU:")) != -1) {
|
||||
|
Loading…
Reference in New Issue
Block a user