This is the mail archive of the gdb-testers@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] Catch exception on solib_svr4_r_ldsomap


*** TEST RESULTS FOR COMMIT 416f679e68468ea6dd7384213994ce74201f82e7 ***

Author: Sergio Durigan Junior <sergiodj@redhat.com>
Branch: master
Commit: 416f679e68468ea6dd7384213994ce74201f82e7

Catch exception on solib_svr4_r_ldsomap
When loading a corefile that has some inaccessible memory region(s),
GDB complains about it:

   (gdb) core /my/corefile
   [New LWP 28468]
   Cannot access memory at address 0x355fc21148
   Cannot access memory at address 0x355fc21140
   (gdb)

However, despite not seeing the message "Core was generated by...", it
is still possible to inspect the corefile using regular GDB commands.
The reason for that is because read_memory_unsigned_integer throws an
exception when it cannot read the memory region, but
solib_svr4_r_ldsomap was not catching it.  The fix is to catch the
exception and act accordingly.

Tested on Fedora 20 x86_64, no regressions found.

gdb/ChangeLog:
2015-03-31  Sergio Durigan Junior  <sergiodj@redhat.com>

	* solib-svr4.c (solib_svr4_r_ldsomap): Catch possible exception by
	read_memory_unsigned_integer.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]