parse_header (struct worker_task *task, f_str_t * line)
{
gchar *headern, *err, *tmp;
+ gboolean res = TRUE;
/* Check end of headers */
if (line->len == 0) {
}
else {
msg_info ("wrong header: %s", headern);
- return FALSE;
+ res = FALSE;
}
break;
case 'h':
}
else {
msg_info ("wrong header: %s", headern);
- return FALSE;
+ res = FALSE;
}
break;
case 'f':
}
else {
msg_info ("wrong header: %s", headern);
- return FALSE;
+ res = FALSE;
}
break;
case 'j':
}
else {
msg_info ("wrong header: %s", headern);
- return FALSE;
+ res = FALSE;
}
break;
case 'q':
}
else {
msg_info ("wrong header: %s", headern);
- return FALSE;
+ res = FALSE;
}
break;
case 'r':
}
else {
msg_info ("wrong header: %s", headern);
- return FALSE;
+ res = FALSE;
}
break;
case 'i':
}
else {
msg_info ("wrong header: %s", headern);
- return FALSE;
+ res = FALSE;
}
break;
case 'p':
}
}
else {
- return FALSE;
+ res = FALSE;
}
break;
case 's':
task->statfile = memory_pool_fstrdup (task->task_pool, line);
}
else {
- return FALSE;
+ res = FALSE;
}
break;
case 'u':
task->user = memory_pool_fstrdup (task->task_pool, line);
}
else {
- return FALSE;
+ res = FALSE;
}
break;
default:
if (!task->is_http) {
msg_info ("wrong header: %s", headern);
- return FALSE;
+ res = FALSE;
}
}
- return TRUE;
+ return res;
}
gboolean