@@ -3,7 +3,7 @@ use winnow::{
3
3
combinator:: { preceded, repeat, terminated} ,
4
4
error:: { AddContext , ParserError , StrContext } ,
5
5
prelude:: * ,
6
- token:: { take_till1 , take_until0, take_while} ,
6
+ token:: { take_till , take_until0, take_while} ,
7
7
Parser ,
8
8
} ;
9
9
@@ -17,9 +17,9 @@ pub(crate) fn any_header_field_multi_line<'a, E: ParserError<&'a [u8]> + AddCont
17
17
i : & mut & ' a [ u8 ] ,
18
18
) -> PResult < ( & ' a [ u8 ] , BString ) , E > {
19
19
(
20
- terminated ( take_till1 ( SPACE_OR_NL ) , SPACE ) ,
20
+ terminated ( take_till ( 1 .. , SPACE_OR_NL ) , SPACE ) ,
21
21
(
22
- take_till1 ( NL ) ,
22
+ take_till ( 1 .. , NL ) ,
23
23
NL ,
24
24
repeat ( 1 .., terminated ( ( SPACE , take_until0 ( NL ) ) , NL ) ) . map ( |( ) | ( ) ) ,
25
25
)
@@ -52,7 +52,7 @@ pub(crate) fn any_header_field<'a, T, E: ParserError<&'a [u8]>>(
52
52
i : & mut & ' a [ u8 ] ,
53
53
parse_value : impl Parser < & ' a [ u8 ] , T , E > ,
54
54
) -> PResult < ( & ' a [ u8 ] , T ) , E > {
55
- terminated ( ( terminated ( take_till1 ( SPACE_OR_NL ) , SPACE ) , parse_value) , NL ) . parse_next ( i)
55
+ terminated ( ( terminated ( take_till ( 1 .. , SPACE_OR_NL ) , SPACE ) , parse_value) , NL ) . parse_next ( i)
56
56
}
57
57
58
58
fn is_hex_digit_lc ( b : u8 ) -> bool {
0 commit comments