From: des Date: Thu, 8 Nov 2007 16:52:40 +0000 (+0000) Subject: Pressing 0-9 will change the delay to the corresponding power of two (e.g. X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=365f82c150181f8c460c1ae0560366971664492f;p=varnish Pressing 0-9 will change the delay to the corresponding power of two (e.g. press 3 for 2^3 = 8 seconds) git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@2231 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- diff --git a/varnish-cache/bin/varnishhist/varnishhist.c b/varnish-cache/bin/varnishhist/varnishhist.c index 0d5b83ec..1457b7cd 100644 --- a/varnish-cache/bin/varnishhist/varnishhist.c +++ b/varnish-cache/bin/varnishhist/varnishhist.c @@ -279,6 +279,18 @@ do_curses(struct VSL_data *vd) case 'q': endwin(); return; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': + delay = 1 << (ch - '0'); + break; default: beep(); break; diff --git a/varnish-cache/bin/varnishstat/varnishstat.c b/varnish-cache/bin/varnishstat/varnishstat.c index ec85884b..674f2ff4 100644 --- a/varnish-cache/bin/varnishstat/varnishstat.c +++ b/varnish-cache/bin/varnishstat/varnishstat.c @@ -148,6 +148,18 @@ do_curses(struct varnish_stats *VSL_stats, int delay) case 'q': endwin(); exit(0); + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + case '8': + case '9': + delay = 1 << (ch - '0'); + break; default: beep(); break;