From 77444fa135c8103b70ebab926b51489b027d7a2a Mon Sep 17 00:00:00 2001 From: Stas Degteff Date: Fri, 9 Jun 2006 06:46:43 +0000 Subject: [PATCH] Re-fix: don't quit on timeout if time is stepped to past. --- golded3/geutil.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/golded3/geutil.cpp b/golded3/geutil.cpp index 3fa293b..6345b9c 100644 --- a/golded3/geutil.cpp +++ b/golded3/geutil.cpp @@ -656,10 +656,10 @@ void call_help() { void CheckTick(gkey quitkey) { - Clock idle_secs = abs(gkbd.tickvalue - gkbd.tickpress) / 10L; + Clock idle_secs = gkbd.tickvalue > gkbd.tickpress? (gkbd.tickvalue - gkbd.tickpress / 10L) : 0; if(CFG->timeout) { - if(((signed long)idle_secs > 0) and (idle_secs >= CFG->timeout)) { + if(idle_secs >= CFG->timeout) { kbput(quitkey); return; }