Index: dbfile.scm ================================================================== --- dbfile.scm +++ dbfile.scm @@ -53,11 +53,11 @@ (define keep-age-param (make-parameter 10)) ;; qif file age, if over move to attic (define num-run-dbs (make-parameter 10)) ;; number of db's in .mtdb (define dbfile:sync-method (make-parameter 'attach)) ;; 'attach or 'original (define dbfile:cache-method (make-parameter 'inmem)) ;; 'direct -(define dbcache-mode (make-parameter 'tmp)) ;; 'inmem, 'tmp (changes what open inmem routine does) +(define dbcache-mode (make-parameter 'inmem)) ;; 'inmem, 'tmp (changes what open inmem routine does) ;; 'original - use old condition code ;; 'suicide-mode - create mtrah/stop-the-train with info on what went wrong ;; else use no condition code (should be production mode) Index: dbmod.scm ================================================================== --- dbmod.scm +++ dbmod.scm @@ -95,11 +95,15 @@ (sync-proc (dbr:dbstruct-sync-proc dbstruct)) (curr-secs (current-seconds))) (if (> (- curr-secs last-update) 3) (begin (sync-proc last-update) - (dbr:dbstruct-last-update-set! dbstruct curr-secs)))) + + ;; MOVE THIS CALL TO INSIDE THE sync-proc CALL + (dbr:dbstruct-last-update-set! dbstruct curr-secs) + + ))) (if use-mutex (mutex-lock! *db-with-db-mutex*)) (let* ((res (apply proc dbdat dbh params))) (if use-mutex (mutex-unlock! *db-with-db-mutex*)) res)))