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 Tuesday 08 March 2011 18:37:55, Michael Snyder wrote:
> @@ -1221,7 +1231,8 @@ i386_skip_noop (CORE_ADDR pc)
>        if (op == 0x90) 
>         {
>           pc += 1;
> -         target_read_memory (pc, &op, 1);
> +         if (target_read_memory (pc, &op, 1))
> +           return pc;

I think you're meant to return PC as it was at function
start.  Note the pc += 1 above.  There are other instances
in the patch.

-- 
Pedro Alves


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