Fixed dbfwfilter rules.

Fixed at_times not working if combined with on_queries.
This commit is contained in:
Markus Makela 2015-04-29 14:29:43 +03:00
parent 1755706ada
commit c190433c7d

View File

@ -977,7 +977,7 @@ bool parse_rule(char* rule, FW_INSTANCE* instance)
TIMERANGE *tr = NULL;
while(tok){
if(strcmp(tok,"on_queries") == 0)
goto reparse_rule;
break;
if(!check_time(tok))
{
skygw_log_write(LOGFILE_ERROR,"dbfwfilter: Rule parsing failed, malformed time definition: %s",tok);
@ -1003,8 +1003,12 @@ bool parse_rule(char* rule, FW_INSTANCE* instance)
tr = tmp;
tok = strtok_r(NULL, " ,",&saveptr);
}
ruledef->active = tr;
if(strcmp(tok,"on_queries") == 0)
goto reparse_rule;
}
else if(strcmp(tok,"regex") == 0)
{