forked from premiere/premiere-libtorrent
replace calls to isspace() with is_space() to avoid asserts in the CRT
This commit is contained in:
parent
2af0ab6e2f
commit
cbe02221cd
|
@ -175,11 +175,11 @@ namespace libtorrent
|
||||||
for (char* i = tag_name_end; i < tag_end; ++i)
|
for (char* i = tag_name_end; i < tag_end; ++i)
|
||||||
{
|
{
|
||||||
// find start of attribute name
|
// find start of attribute name
|
||||||
for (; i != tag_end && isspace(*i); ++i);
|
for (; i != tag_end && is_space(*i); ++i);
|
||||||
if (i == tag_end) break;
|
if (i == tag_end) break;
|
||||||
start = i;
|
start = i;
|
||||||
// find end of attribute name
|
// find end of attribute name
|
||||||
for (; i != tag_end && *i != '=' && !isspace(*i); ++i);
|
for (; i != tag_end && *i != '=' && !is_space(*i); ++i);
|
||||||
char* name_end = i;
|
char* name_end = i;
|
||||||
|
|
||||||
// look for equality sign
|
// look for equality sign
|
||||||
|
@ -195,7 +195,7 @@ namespace libtorrent
|
||||||
}
|
}
|
||||||
|
|
||||||
++i;
|
++i;
|
||||||
for (; i != tag_end && isspace(*i); ++i);
|
for (; i != tag_end && is_space(*i); ++i);
|
||||||
// check for parse error (values must be quoted)
|
// check for parse error (values must be quoted)
|
||||||
if (i == tag_end || (*i != '\'' && *i != '\"'))
|
if (i == tag_end || (*i != '\'' && *i != '\"'))
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue