From 48c908453d8fe2a78610b523dfd88c54d4192252 Mon Sep 17 00:00:00 2001 From: Marlene Cota Date: Tue, 30 Apr 2024 12:41:29 -0700 Subject: [PATCH] Fix CodeQL alert (#3945) --- include/fmt/base.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/fmt/base.h b/include/fmt/base.h index 5acd3e64..772bc02a 100644 --- a/include/fmt/base.h +++ b/include/fmt/base.h @@ -1899,7 +1899,7 @@ template class basic_format_args { if (id < max_size()) arg = args_[id]; return arg; } - if (id >= detail::max_packed_args) return arg; + if (static_cast(id) >= detail::max_packed_args) return arg; arg.type_ = type(id); if (arg.type_ == detail::type::none_type) return arg; arg.value_ = values_[id];