diff options
author | Richard Henderson <richard.henderson@linaro.org> | 2024-02-27 06:34:18 -1000 |
---|---|---|
committer | Richard Henderson <richard.henderson@linaro.org> | 2024-02-29 11:03:39 -1000 |
commit | 243c47066253c4236b8792ee158f9971d1c27bf9 (patch) | |
tree | d598a96ec0f65085ed5f466ca566189fb0516f54 /python | |
parent | 2410d28dc992082ec3348d6544ef30c1f950c8b9 (diff) | |
download | qemu-243c47066253c4236b8792ee158f9971d1c27bf9.zip qemu-243c47066253c4236b8792ee158f9971d1c27bf9.tar.gz qemu-243c47066253c4236b8792ee158f9971d1c27bf9.tar.bz2 |
linux-user/elfload: Write corefile elf header in one block
Fixes a bug in which write_note() wrote namesz_rounded
and datasz_rounded bytes, even though name and data
pointers contain only the unrounded number of bytes.
Instead of many small writes, allocate a block to contain all
of the elf headers and all of the notes. Copy the data into the
block piecemeal and the write it to the file as a chunk.
This also avoids the need to lseek forward for alignment.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'python')
0 files changed, 0 insertions, 0 deletions