CID 420802: Avoid NULL deref.
This commit is contained in:
parent
29b05d6a28
commit
0e580577fe
2
external/gpl3/gdb/dist/bfd/merge.c
vendored
2
external/gpl3/gdb/dist/bfd/merge.c
vendored
@ -334,7 +334,7 @@ sec_merge_emit (bfd *abfd, struct sec_merge_hash_entry *entry,
|
|||||||
|
|
||||||
/* Trailing alignment needed? */
|
/* Trailing alignment needed? */
|
||||||
off = sec->size - off;
|
off = sec->size - off;
|
||||||
if (off != 0)
|
if (pad != NULL && off != 0)
|
||||||
{
|
{
|
||||||
if (contents)
|
if (contents)
|
||||||
memcpy (contents + offset, pad, off);
|
memcpy (contents + offset, pad, off);
|
||||||
|
Loading…
Reference in New Issue
Block a user