mirror of
https://git.proxmox.com/git/libgit2
synced 2025-05-02 16:20:01 +00:00
Updating change to http_parser to reflect PR for nodejs/http-parser
The parser now also supports digits, '-' and '.'. https://github.com/nodejs/http-parser/pull/276
This commit is contained in:
parent
0c1f56722b
commit
0b1e6e42e3
5
deps/http-parser/http_parser.c
vendored
5
deps/http-parser/http_parser.c
vendored
@ -444,6 +444,9 @@ parse_url_char(enum state s, const char ch)
|
||||
return s_req_path;
|
||||
}
|
||||
|
||||
/* The schema must start with an alpha character. After that, it may
|
||||
* consist of digits, '+', '-' or '.', followed by a ':'.
|
||||
*/
|
||||
if (IS_ALPHA(ch)) {
|
||||
return s_req_schema;
|
||||
}
|
||||
@ -451,7 +454,7 @@ parse_url_char(enum state s, const char ch)
|
||||
break;
|
||||
|
||||
case s_req_schema:
|
||||
if (IS_ALPHA(ch) || ch == '+') {
|
||||
if (IS_ALPHANUM(ch) || ch == '+' || ch == '-' || ch == '.') {
|
||||
return s;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user