diff options
author | Alan Modra <amodra@gmail.com> | 2021-11-01 00:20:01 +1030 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2021-11-01 22:30:33 +1030 |
commit | c27cdb4c534e0b52ea877b6800f832756ee16a2f (patch) | |
tree | 3fd83f8cef38b521a12115be882cdbebbf713f12 /libiberty/cplus-dem.c | |
parent | 3197e593d8a2a79a23dc9155d18d7aff6281da14 (diff) | |
download | fsf-binutils-gdb-c27cdb4c534e0b52ea877b6800f832756ee16a2f.zip fsf-binutils-gdb-c27cdb4c534e0b52ea877b6800f832756ee16a2f.tar.gz fsf-binutils-gdb-c27cdb4c534e0b52ea877b6800f832756ee16a2f.tar.bz2 |
objcopy buffer overflow
"tocopy" in this code was an int, which when the size to be copied was
larger than MAXINT could result in tocopy being negative. A negative
value of course is less than BUFSIZE, but when converted to
bfd_size_type is extremely large.
PR 995
* objcopy.c (copy_unknown_object): Correct calculation of "tocopy".
Use better variable types.
Diffstat (limited to 'libiberty/cplus-dem.c')
0 files changed, 0 insertions, 0 deletions