diff options
author | Philipp Sehmisch <tmw@crushnet.org> | 2006-04-30 10:47:02 +0000 |
---|---|---|
committer | Philipp Sehmisch <tmw@crushnet.org> | 2006-04-30 10:47:02 +0000 |
commit | 46cf9258d20113a48f7d5811ea112df6504dc30e (patch) | |
tree | 031e25852528373a0d3dacb7d36161f0ae9b6130 /src/utils/timer.cpp | |
parent | ecc2253758c536753036ae4ab5ed5e7b1d891c8d (diff) | |
download | manaserv-46cf9258d20113a48f7d5811ea112df6504dc30e.tar.gz manaserv-46cf9258d20113a48f7d5811ea112df6504dc30e.tar.bz2 manaserv-46cf9258d20113a48f7d5811ea112df6504dc30e.tar.xz manaserv-46cf9258d20113a48f7d5811ea112df6504dc30e.zip |
made sure every compiler uses a 64bit unsigned integer for getTimeInMillisec.
Diffstat (limited to 'src/utils/timer.cpp')
-rw-r--r-- | src/utils/timer.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/utils/timer.cpp b/src/utils/timer.cpp index 25d96cbc..97965c75 100644 --- a/src/utils/timer.cpp +++ b/src/utils/timer.cpp @@ -26,7 +26,7 @@ namespace tmwserv namespace utils { -Timer::Timer(signed int ms, bool createActive) +Timer::Timer(unsigned int ms, bool createActive) { active = createActive; interval = ms; @@ -55,18 +55,18 @@ void Timer::stop() active = false; }; -void Timer::changeInterval(signed int newinterval) +void Timer::changeInterval(unsigned int newinterval) { interval = newinterval; }; -signed long long int Timer::getTimeInMillisec() +uint64_t Timer::getTimeInMillisec() { - signed long long int timeInMillisec; + uint64_t timeInMillisec; timeval time; gettimeofday(&time, 0); - timeInMillisec = (signed long long int)time.tv_sec * 1000 + time.tv_usec / 1000; + timeInMillisec = (uint64_t)time.tv_sec * 1000 + time.tv_usec / 1000; return timeInMillisec; }; |