This is the mail archive of the gdb-patches@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]

Re: [RFA] i386-tdep.c, check target_read_memory for error.


On Fri, 04 Mar 2011 22:37:52 +0100, Michael Snyder wrote:
> Call error if target_read_memory fails.
[...]
> -  target_read_memory (pc, &op, 1);
> +  if (target_read_memory (pc, &op, 1))
> +    error (_("Couldn't read memory at pc (%s)"), 
> +	   paddress (gdbarch, pc));

There is the function `read_memory' for such purpose.


Thanks,
Jan


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