]> git.ipfire.org Git - thirdparty/ipxe.git/commit
[efi] Avoid modifying PE/COFF debug filename
authorMichael Brown <mcb30@ipxe.org>
Wed, 29 Nov 2023 12:49:06 +0000 (12:49 +0000)
committerMichael Brown <mcb30@ipxe.org>
Wed, 29 Nov 2023 12:49:06 +0000 (12:49 +0000)
commit98dd25a3bb2d3aafa71f088cbabf89418a783132
tree37f5e66f0e933c9d921e6aeb7a823a602033e4ad
parenta147245f1a2f92a85a75226ea921acb22322ab4d
[efi] Avoid modifying PE/COFF debug filename

The function efi_pecoff_debug_name() (called by efi_handle_name()) is
used to extract a filename from the debug data directory entry located
within a PE/COFF image.  The name is copied into a temporary static
buffer to allow for modifications, but the code currently erroneously
modifies the original name within the loaded PE/COFF image.

Fix by performing the modification on the copy in the temporary
buffer, as originally intended.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/interface/efi/efi_debug.c