Avoid using alloca(3) to unbreak SSP builds.
This commit is contained in:
parent
71b58bd028
commit
59c9daa5b3
4
external/gpl3/binutils/dist/gas/remap.c
vendored
4
external/gpl3/binutils/dist/gas/remap.c
vendored
@ -82,8 +82,8 @@ remap_debug_filename (const char *filename)
|
||||
return filename;
|
||||
name = filename + map->old_len;
|
||||
name_len = strlen (name) + 1;
|
||||
s = (char *) alloca (name_len + map->new_len);
|
||||
s = (char *) xmalloc (name_len + map->new_len);
|
||||
memcpy (s, map->new_prefix, map->new_len);
|
||||
memcpy (s + map->new_len, name, name_len);
|
||||
return xstrdup (s);
|
||||
return s;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user