mirror of
https://github.com/fmtlib/fmt.git
synced 2025-01-10 06:20:09 +00:00
Fix asan error (#977)
This commit is contained in:
parent
b180b39152
commit
de71db6d42
@ -1952,8 +1952,8 @@ FMT_CONSTEXPR const Char *parse_arg_id(
|
|||||||
return handler.on_error("invalid format string"), begin;
|
return handler.on_error("invalid format string"), begin;
|
||||||
auto it = begin;
|
auto it = begin;
|
||||||
do {
|
do {
|
||||||
c = *++it;
|
++it;
|
||||||
} while (it != end && (is_name_start(c) || ('0' <= c && c <= '9')));
|
} while (it != end && (is_name_start(c = *it) || ('0' <= c && c <= '9')));
|
||||||
handler(basic_string_view<Char>(begin, to_unsigned(it - begin)));
|
handler(basic_string_view<Char>(begin, to_unsigned(it - begin)));
|
||||||
return it;
|
return it;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user