This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] PR gdb/15871: Unavailable entry value is not shown correctly
- From: Yao Qi <yao at codesourcery dot com>
- To: Pedro Alves <palves at redhat dot com>
- Cc: Mark Kettenis <mark dot kettenis at xs4all dot nl>, <tromey at redhat dot com>, <gdb-patches at sourceware dot org>
- Date: Thu, 22 Aug 2013 09:24:17 +0800
- Subject: Re: [PATCH] PR gdb/15871: Unavailable entry value is not shown correctly
- References: <1376379586-24150-1-git-send-email-yao at codesourcery dot com> <1376379586-24150-3-git-send-email-yao at codesourcery dot com> <87siy4gsn4 dot fsf at fleche dot redhat dot com> <521458A8 dot 7060304 at codesourcery dot com> <5214D03C dot 9040703 at redhat dot com> <201308211447 dot r7LEld3t025510 at glazunov dot sibelius dot xs4all dot nl> <5214DD85 dot 5060605 at redhat dot com>
On 08/21/2013 11:32 PM, Pedro Alves wrote:
I looked
around a bit over memory_error calls, and the need to handle random
errno values, other than the EIOs gdb itself hardcodes, probably comes
(only) from deprecated_xfer_memory, which uses errno for error
Is it in function default_xfer_partial?
indication, but I didn't look exhaustively. We should really get rid
of that...)
What do you mean by "that"? using errno for error indication?
+/* Report a target xfer memory error by throwing a suitable
+ exception. */
+
+static void
+target_xfer_memory_error (enum target_xfer_error err, CORE_ADDR memaddr)
+{
+ switch (err)
+ {
+ case TARGET_XFER_E_IO:
+ /* Actually, address between memaddr and memaddr + len was out of
+ bounds. */
This line of comment doesn't make much sense in the context of this
function.
This patch looks good to me. Please commit it without the change to
gdb.trace/entry-values.exp, and I'll update my patch to remove kfail.
A suggestion here, IWBN to print the string of 'enum target_xfer_error'
in the debugging message at the end of target_xfer_partial. We are
print numbers currently.
--
Yao (éå)