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]

[patch] gdbserver regcache fetch all regs


Hello,

I believe this is a bug in gdbserver/regcache.c

Current code fetches regno 0 and marks regcache valid. I believe correct should be: fetch all regs, and mark regache valid.

Thanks,

--
Aleksandar Ristovski
QNX Software Systems


ChangeLog:



* regcache.c (get_regcache): Fetch all registers instead of regno 0 only.
Index: regcache.c
===================================================================
RCS file: /cvs/src/src/gdb/gdbserver/regcache.c,v
retrieving revision 1.19
diff -u -p -r1.19 regcache.c
--- regcache.c	22 Mar 2009 23:57:10 -0000	1.19
+++ regcache.c	17 Jun 2009 01:21:03 -0000
@@ -53,7 +53,7 @@ get_regcache (struct thread_info *inf, i
   /* FIXME - fetch registers for INF */
   if (fetch && regcache->registers_valid == 0)
     {
-      fetch_inferior_registers (0);
+      fetch_inferior_registers (-1);
       regcache->registers_valid = 1;
     }
 

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