mirror of
https://github.com/libretro/RetroArch
synced 2025-02-28 12:40:23 +00:00
fix netplay UPNP binding for specific router behavior (#13399)
* fix netplay UPNP binding for specific router behavior * use ISSPACE macro
This commit is contained in:
parent
c752f9b0de
commit
e0ad9f7e26
@ -197,6 +197,7 @@ rxml_document_t *rxml_load_document_string(const char *str)
|
|||||||
node->name = strdup(x.elem);
|
node->name = strdup(x.elem);
|
||||||
|
|
||||||
attr = NULL;
|
attr = NULL;
|
||||||
|
valptr = buf->val;
|
||||||
|
|
||||||
++level;
|
++level;
|
||||||
break;
|
break;
|
||||||
|
@ -919,11 +919,14 @@ bool net_http_update(struct http_t *state, size_t* progress, size_t* total)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (string_starts_with_case_insensitive(state->data, "Content-Length: "))
|
if (string_starts_with_case_insensitive(state->data, "Content-Length:"))
|
||||||
{
|
{
|
||||||
|
char* ptr = state->data + STRLEN_CONST("Content-Length:");
|
||||||
|
while (ISSPACE(*ptr))
|
||||||
|
++ptr;
|
||||||
|
|
||||||
state->bodytype = T_LEN;
|
state->bodytype = T_LEN;
|
||||||
state->len = strtol(state->data +
|
state->len = strtol(ptr, NULL, 10);
|
||||||
STRLEN_CONST("Content-Length: "), NULL, 10);
|
|
||||||
}
|
}
|
||||||
if (string_is_equal_case_insensitive(state->data, "Transfer-Encoding: chunked"))
|
if (string_is_equal_case_insensitive(state->data, "Transfer-Encoding: chunked"))
|
||||||
state->bodytype = T_CHUNK;
|
state->bodytype = T_CHUNK;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user