lua_http_maybe_free (struct lua_http_cbdata *cbd)
{
if (cbd->session) {
- rspamd_session_watcher_pop (cbd->session, cbd->w);
rspamd_session_remove_event (cbd->session, lua_http_fin, cbd);
+ rspamd_session_watcher_pop (cbd->session, cbd->w);
}
else {
lua_http_fin (cbd);
cbd,
g_quark_from_static_string ("lua http"));
cbd->w = rspamd_session_get_watcher (session);
- rspamd_session_watcher_push (session);
+ rspamd_session_watcher_push_specific (session, cbd->w);
}
if (rspamd_parse_inet_address (&cbd->addr, msg->host->str, msg->host->len)) {
cache_url(task, orig_url, url, key, param)
elseif code == 301 or code == 302 then
local loc = headers['Location']
- rspamd_logger.infox(task, 'found redirect from %s to %s, err code 200',
- orig_url, loc)
+ rspamd_logger.infox(task, 'found redirect from %s to %s, err code %s',
+ orig_url, loc, code)
if loc then
if settings.redirectors_only then
if rspamd_plugins.surbl.is_redirector(task, loc) then