Skip to content
Snippets Groups Projects
Commit d56e433a authored by Alan Modra's avatar Alan Modra
Browse files

Re: Sanity check read_section_stabs_debugging_info

	* rddbg.c (read_section_stabs_debugging_info): Don't segfault on
	zero size string section.
parent 5a8b54ae
No related branches found
No related tags found
No related merge requests found
......@@ -147,7 +147,8 @@ read_section_stabs_debugging_info (bfd *abfd, asymbol **syms, long symcount,
}
/* Zero terminate the strings table, just in case. */
strsize = bfd_section_size (strsec);
strings [strsize - 1] = 0;
if (strsize != 0)
strings [strsize - 1] = 0;
if (shandle == NULL)
{
shandle = start_stab (dhandle, abfd, true, syms, symcount);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment