[bknr-cvs] r2281 - branches/trunk-reorg/bknr/datastore/src/data

bknr at bknr.net bknr at bknr.net
Wed Nov 14 15:28:14 UTC 2007


Author: hhubner
Date: 2007-11-14 10:28:13 -0500 (Wed, 14 Nov 2007)
New Revision: 2281

Modified:
   branches/trunk-reorg/bknr/datastore/src/data/txn.lisp
Log:
Revive accidentially removed lines.


Modified: branches/trunk-reorg/bknr/datastore/src/data/txn.lisp
===================================================================
--- branches/trunk-reorg/bknr/datastore/src/data/txn.lisp	2007-11-14 07:35:39 UTC (rev 2280)
+++ branches/trunk-reorg/bknr/datastore/src/data/txn.lisp	2007-11-14 15:28:13 UTC (rev 2281)
@@ -137,14 +137,16 @@
       (with-open-file (f (store-random-state-pathname store))
 	(format t "reading store random state~%")
 	(setf (store-random-state store) (read f)))
-      (with-open-file (f (store-random-state-pathname store) :direction :output :if-does-not-exist :create)
+      (with-open-file (f (store-random-state-pathname store)
+                         :direction :output :if-does-not-exist :create :if-exists :supersede)
 	(format t "initializing store random state~%")
 	(with-standard-io-syntax
 	  (prin1 (setf (store-random-state store) (make-random-state t)) f)))))
 
 (defmethod update-store-random-state ((store store))
   (format t "saving store random state~%")
-  (with-open-file (f (store-random-state-pathname store) :direction :output :if-does-not-exist :create)
+  (with-open-file (f (store-random-state-pathname store)
+                     :direction :output :if-does-not-exist :create :if-exists :supersede)
     (with-standard-io-syntax
       (prin1 (store-random-state store) f))))
 
@@ -478,10 +480,11 @@
 			 (format *trace-output* "Snapshotting subsystem ~A of ~A~%" subsystem store))
 		       (snapshot-subsystem store subsystem)
 		       (when *store-debug*
-			 (format *trace-output* "Successfully snapshotted ~A of ~A~%" subsystem store))))
+			 (format *trace-output* "Successfully snapshotted ~A of ~A~%" subsystem store)))
+                   (setf (store-transaction-run-time store) 0)
+                   (setf error nil))
               (when error
-		(warn "Restoring backup ~A to current."
-		      backup-directory)
+		(warn "Restoring backup ~A to current." backup-directory)
 		(rename-file backup-directory (store-current-directory store))))))))))
 
 (defvar *show-transactions* nil)




More information about the Bknr-cvs mailing list