mirror of
https://git.savannah.gnu.org/git/make.git
synced 2024-10-24 05:09:58 +00:00
Formerly main.c.~87~
This commit is contained in:
parent
55f5d979ae
commit
074d147ef7
1 changed files with 9 additions and 4 deletions
13
main.c
13
main.c
|
@ -712,8 +712,11 @@ main (argc, argv, envp)
|
||||||
/* Replace the name that read_all_makefiles will
|
/* Replace the name that read_all_makefiles will
|
||||||
see with the name of the temporary file. */
|
see with the name of the temporary file. */
|
||||||
{
|
{
|
||||||
makefiles->list[i] = (char *) alloca (sizeof (name));
|
char *temp;
|
||||||
bcopy (name, makefiles->list[i], sizeof (name));
|
/* SGI compiler requires alloca's result be assigned simply. */
|
||||||
|
temp = (char *) alloca (sizeof (name));
|
||||||
|
bcopy (name, temp, sizeof (name));
|
||||||
|
makefiles->list[i] = temp;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Make sure the temporary file will not be remade. */
|
/* Make sure the temporary file will not be remade. */
|
||||||
|
@ -1436,8 +1439,10 @@ decode_env_switches (envar, len)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
/* Make a copy of the value in ARGS, where we will munge it.
|
/* Make a copy of the value in ARGS, where we will munge it.
|
||||||
If it does not begin with a dash, prepend one. */
|
If it does not begin with a dash, prepend one.
|
||||||
args = (char *) alloca (1 + len + 2);
|
We must allocate lasting storage for this (and we never free it) because
|
||||||
|
decode_switches may save pointers into it for string-valued switches. */
|
||||||
|
args = (char *) xmalloc (1 + len + 2);
|
||||||
if (value[0] != '-')
|
if (value[0] != '-')
|
||||||
args[0] = '-';
|
args[0] = '-';
|
||||||
bcopy (value, value[0] == '-' ? args : &args[1], len + 1);
|
bcopy (value, value[0] == '-' ? args : &args[1], len + 1);
|
||||||
|
|
Loading…
Reference in a new issue