comparison mod_firewall/definitions.lib.lua @ 2587:8c879948a2cf

mod_firewall: Remove unused variable assignment
author Matthew Wild <mwild1@gmail.com>
date Sun, 26 Feb 2017 11:29:10 +0000
parents d28e434cb5fd
children 22e11645a895
comparison
equal deleted inserted replaced
2586:d28e434cb5fd 2587:8c879948a2cf
117 module:log("debug", "Fetched updated list from <%s>", url); 117 module:log("debug", "Fetched updated list from <%s>", url);
118 elseif code == 304 then 118 elseif code == 304 then
119 module:log("debug", "List at <%s> is unchanged", url); 119 module:log("debug", "List at <%s> is unchanged", url);
120 elseif code == 0 or (code >= 400 and code <=599) then 120 elseif code == 0 or (code >= 400 and code <=599) then
121 module:log("warn", "Failed to fetch list from <%s>: %d %s", url, code, tostring(body)); 121 module:log("warn", "Failed to fetch list from <%s>: %d %s", url, code, tostring(body));
122 next_poll = 300;
123 failure_count = failure_count + 1; 122 failure_count = failure_count + 1;
124 next_poll = retry_intervals[failure_count] or retry_intervals[#retry_intervals]; 123 next_poll = retry_intervals[failure_count] or retry_intervals[#retry_intervals];
125 end 124 end
126 if next_poll > 0 then 125 if next_poll > 0 then
127 timer.add_task(next_poll+math.random(0, 60), update_list); 126 timer.add_task(next_poll+math.random(0, 60), update_list);