Klaus Demo nginx / 81924e8
compatibility with mget: space after HTTP/1.1 Igor Sysoev 14 years ago
1 changed file(s) with 20 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
123123 sw_major_digit,
124124 sw_first_minor_digit,
125125 sw_minor_digit,
126 sw_spaces_after_digit,
126127 sw_almost_done
127128 } state;
128129
635636 goto done;
636637 }
637638
639 if (ch == ' ') {
640 state = sw_spaces_after_digit;
641 break;
642 }
643
638644 if (ch < '0' || ch > '9') {
639645 return NGX_HTTP_PARSE_INVALID_REQUEST;
640646 }
641647
642648 r->http_minor = r->http_minor * 10 + ch - '0';
649 break;
650
651 case sw_spaces_after_digit:
652 switch (ch) {
653 case ' ':
654 break;
655 case CR:
656 state = sw_almost_done;
657 break;
658 case LF:
659 goto done;
660 default:
661 return NGX_HTTP_PARSE_INVALID_REQUEST;
662 }
643663 break;
644664
645665 /* end of request line */