From f9b09368f063cdace93a042d5bdd45987c084d94 Mon Sep 17 00:00:00 2001 From: est31 Date: Tue, 3 Nov 2015 08:56:56 +0100 Subject: Time: Remove serverside getter, and use atomic operations It isn't possible to use atomic operations for floats, so don't use them there. Having a lock is good out of other reasons too, because this way the float time and the integer time both match, and can't get different values in a race, e.g. when two setTimeofDay() get executed simultaneously. --- src/server.h | 1 - 1 file changed, 1 deletion(-) (limited to 'src/server.h') diff --git a/src/server.h b/src/server.h index 3ec889971..bee978de2 100644 --- a/src/server.h +++ b/src/server.h @@ -223,7 +223,6 @@ public: // Both setter and getter need no envlock, // can be called freely from threads void setTimeOfDay(u32 time); - inline u32 getTimeOfDay(); /* Shall be called with the environment locked. -- cgit v1.2.3