diff options
author | Matthew Wild <mwild1@gmail.com> | 2012-05-18 04:22:51 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2012-05-18 04:22:51 +0100 |
commit | e4da795611c0e87a93d97f397a74f02a7b2d9f7d (patch) | |
tree | 0ad843f882da9ddce5b3fd679d4ee6074de02c3f /util | |
parent | 14b50e4d76a5870c734d4d9b41b482448cd00e97 (diff) | |
download | prosody-e4da795611c0e87a93d97f397a74f02a7b2d9f7d.tar.gz prosody-e4da795611c0e87a93d97f397a74f02a7b2d9f7d.zip |
util.watchdog: Pass watchdog object to callback so that it doesn't always have to be a closure
Diffstat (limited to 'util')
-rw-r--r-- | util/watchdog.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/util/watchdog.lua b/util/watchdog.lua index 96031415..bcb2e274 100644 --- a/util/watchdog.lua +++ b/util/watchdog.lua @@ -16,7 +16,7 @@ function new(timeout, callback) end local time_left = (last_reset + timeout) - current_time; if time_left < 0 then - return watchdog.callback(); + return watchdog:callback(); end return time_left + 1; end); |