From: noname@inventati.org <noname@inventati.org>
Date: Sat, 18 Apr 2015 16:45:48 +0000 (+0200)
Subject: Increment accuaracy in drawtime calculation
X-Git-Url: https://git.owens.tech/112-editable-focus.html/112-editable-focus.html/git?a=commitdiff_plain;h=6dc2b546eca11b198c64c9047106970a8d1f85e8;p=st.git

Increment accuaracy in drawtime calculation

This way is a bit more accurate.
---

diff --git a/st.c b/st.c
index c7589f4..dcb80ca 100644
--- a/st.c
+++ b/st.c
@@ -3992,7 +3992,7 @@ run(void) {
 
 		clock_gettime(CLOCK_MONOTONIC, &now);
 		drawtimeout.tv_sec = 0;
-		drawtimeout.tv_nsec = (1000/xfps) * 1E6;
+		drawtimeout.tv_nsec =  (1000 * 1E6)/ xfps;
 		tv = &drawtimeout;
 
 		dodraw = 0;