Fix an illegal memory access in the assembler when generating a DWARF5 file/directory...
authorNick Clifton <nickc@redhat.com>
Mon, 4 May 2020 09:19:38 +0000 (10:19 +0100)
committerNick Clifton <nickc@redhat.com>
Mon, 4 May 2020 09:19:38 +0000 (10:19 +0100)
commit4706679daca21b5d637afaf5b55858b26f0f8c16
tree8950f5eb3edfacd8a64ff517515f9144daf5f624
parent6015a0674901be2c3fd24867e1a610d2abf8c1a0
Fix an illegal memory access in the assembler when generating a DWARF5 file/directory table with no entries.

PR 25917
* dwarf2dbg.c (out_dir_and_file_list): Check for the directory
table's existence before looking at its entries.
* testsuite/gas/elf/pr25917.s: New test source file.
* testsuite/gas/elf/pr25917.d: New test driver.
* testsuite/gas/elf/elf.exp (run_elf_list_test): Run the new test.
gas/ChangeLog
gas/dwarf2dbg.c
gas/testsuite/gas/elf/elf.exp
gas/testsuite/gas/elf/pr25917.d [new file with mode: 0644]
gas/testsuite/gas/elf/pr25917.s [new file with mode: 0644]