Software / code / prosody
Changeset
4891:189cfe565d03
util.watchdog: Pass watchdog object to callback so that it doesn't always have to be a closure
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Fri, 18 May 2012 04:22:51 +0100 |
| parents | 4890:7d4ec9609957 |
| children | 4892:6c8074f47ca4 |
| files | util/watchdog.lua |
| diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/util/watchdog.lua Fri May 18 01:50:51 2012 +0100 +++ b/util/watchdog.lua Fri May 18 04:22:51 2012 +0100 @@ -16,7 +16,7 @@ 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);