public inbox for frysk-cvs@sourceware.org
help / color / mirror / Atom feed
* [SCM]  master: Maintain previous value of watched variable in WatchpointObserver.
@ 2008-05-28 19:23 tthomas
  0 siblings, 0 replies; only message in thread
From: tthomas @ 2008-05-28 19:23 UTC (permalink / raw)
  To: frysk-cvs

The branch, master has been updated
       via  81647a994c50b61d87ec8ff4eedc079990f7e4bb (commit)
      from  3a848ec1396198a762420c60d340cf0cf77b2b11 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit 81647a994c50b61d87ec8ff4eedc079990f7e4bb
Author: Teresa Thomas <tthomas@redhat.com>
Date:   Wed May 28 15:25:44 2008 -0400

    Maintain previous value of watched variable in WatchpointObserver.
    
    frysk-core/frysk/rt/ChangeLog:
    2008-05-28  Teresa Thomas  <tthomas@redhat.com>
    
    	* WatchObserverInstaller.java (WatchpointObserver):
    	Maintain oldValue here.

-----------------------------------------------------------------------

Summary of changes:
 frysk-core/frysk/rt/ChangeLog                   |    3 +++
 frysk-core/frysk/rt/WatchObserverInstaller.java |   11 ++++-------
 2 files changed, 7 insertions(+), 7 deletions(-)

First 500 lines of diff:
diff --git a/frysk-core/frysk/rt/ChangeLog b/frysk-core/frysk/rt/ChangeLog
index abf6639..82cf8e7 100644
--- a/frysk-core/frysk/rt/ChangeLog
+++ b/frysk-core/frysk/rt/ChangeLog
@@ -1,5 +1,8 @@
 2008-05-28  Teresa Thomas  <tthomas@redhat.com>
 
+	* WatchObserverInstaller.java (WatchpointObserver):
+	Maintain oldValue here.
+	
 	* WatchObserverInstaller.java (oldValue): Make static. 
 	
 	* WatchObserverInstaller.java: New file.
diff --git a/frysk-core/frysk/rt/WatchObserverInstaller.java b/frysk-core/frysk/rt/WatchObserverInstaller.java
index 885f43c..3d0bfd6 100644
--- a/frysk-core/frysk/rt/WatchObserverInstaller.java
+++ b/frysk-core/frysk/rt/WatchObserverInstaller.java
@@ -61,11 +61,6 @@ public class WatchObserverInstaller {
     
     private static int watchpointsInUse = 0;
     
-    // Maintain oldValue statically so that changes made to a 
-    // a value being watched by multiple watchpoints are
-    // are reflected in all watch observers.
-    private static String oldValue = "";
-    
     Expression expr;
     String exprString;
     SteppingEngine ste;
@@ -137,6 +132,7 @@ public class WatchObserverInstaller {
 	String exprString;
 	SteppingEngine ste;
 	PrintWriter writer;
+	String oldValue;
 	Task task;
 	
 	WatchpointObserver(Expression expr, String exprStr, Task task,
@@ -146,8 +142,9 @@ public class WatchObserverInstaller {
 	    this.ste = ste;
 	    this.writer = writer;
 	    this.task = task;
+	    this.oldValue = "";
+
 	}
-	
 	public Action updateHit(Task task, long address, int length) {
 
 	    String newValue = expr.getValue().toPrint
@@ -173,7 +170,7 @@ public class WatchObserverInstaller {
 	    watchpointsInUse++;
 	    // XXX: getValue may modify inferior.
 	    oldValue = expr.getValue().toPrint
-	               (Format.NATURAL, task.getMemory());	    
+	                      (Format.NATURAL, task.getMemory());	    
 	}
 
 	public void deletedFrom(Object observable) {


hooks/post-receive
--
frysk system monitor/debugger


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-05-28 19:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-05-28 19:23 [SCM] master: Maintain previous value of watched variable in WatchpointObserver tthomas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).