fmt-10.2.1-4.fc41

List of Defects

Error: CPPCHECK_WARNING (CWE-562): [#def1]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/core.h:790: error[returnTempReference]: Reference to temporary returned.
#  788|       using base::container;
#  789|     };
#  790|->   return *accessor(it).container;
#  791|   }
#  792|   

Error: CPPCHECK_WARNING (CWE-398): [#def2]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/core.h:2174: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
# 2172|   FMT_CONSTEXPR auto parse_nonnegative_int(const Char*& begin, const Char* end,
# 2173|                                            int error_value) noexcept -> int {
# 2174|->   FMT_ASSERT(begin != end && '0' <= *begin && *begin <= '9', "");
# 2175|     unsigned value = 0, prev = 0;
# 2176|     auto p = begin;

Error: CPPCHECK_WARNING (CWE-398): [#def3]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:58: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
#   56|       ++error_code_size;
#   57|     }
#   58|->   error_code_size += detail::to_unsigned(detail::count_digits(abs_value));
#   59|     auto it = buffer_appender<char>(out);
#   60|     if (message.size() <= inline_buffer_size - error_code_size)

Error: CPPCHECK_WARNING (CWE-398): [#def4]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:198: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
#  196|   // Various fast log computations.
#  197|   inline auto floor_log10_pow2_minus_log10_4_over_3(int e) noexcept -> int {
#  198|->   FMT_ASSERT(e <= 2936 && e >= -2985, "too large exponent");
#  199|     return (e * 631305 - 261663) >> 21;
#  200|   }

Error: CPPCHECK_WARNING (CWE-398): [#def5]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:224: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
#  222|     // The idea for item 2 originates from Schubfach.
#  223|     constexpr auto info = div_small_pow10_infos[N - 1];
#  224|->   FMT_ASSERT(n <= info.divisor * 10, "n is too large");
#  225|     constexpr uint32_t magic_number =
#  226|         (1u << info.shift_amount) / info.divisor + 1;

Error: CPPCHECK_WARNING (CWE-398): [#def6]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:238: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
#  236|   template <int N> auto small_division_by_pow10(uint32_t n) noexcept -> uint32_t {
#  237|     constexpr auto info = div_small_pow10_infos[N - 1];
#  238|->   FMT_ASSERT(n <= info.divisor * 10, "n is too large");
#  239|     constexpr uint32_t magic_number =
#  240|         (1u << info.shift_amount) / info.divisor + 1;

Error: CPPCHECK_WARNING (CWE-398): [#def7]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:263: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
#  261|   
#  262|     static auto get_cached_power(int k) noexcept -> uint64_t {
#  263|->     FMT_ASSERT(k >= float_info<float>::min_k && k <= float_info<float>::max_k,
#  264|                  "k is out of range");
#  265|       static constexpr const uint64_t pow10_significands[] = {

Error: CPPCHECK_WARNING (CWE-398): [#def8]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:321: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
#  319|                                    int beta) noexcept
#  320|         -> compute_mul_parity_result {
#  321|->     FMT_ASSERT(beta >= 1, "");
#  322|       FMT_ASSERT(beta < 64, "");
#  323|   

Error: CPPCHECK_WARNING (CWE-398): [#def9]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:357: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
#  355|   
#  356|     static auto get_cached_power(int k) noexcept -> uint128_fallback {
#  357|->     FMT_ASSERT(k >= float_info<double>::min_k && k <= float_info<double>::max_k,
#  358|                  "k is out of range");
#  359|   

Error: CPPCHECK_WARNING (CWE-398): [#def10]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:1096: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
# 1094|                                    int beta) noexcept
# 1095|         -> compute_mul_parity_result {
# 1096|->     FMT_ASSERT(beta >= 1, "");
# 1097|       FMT_ASSERT(beta < 64, "");
# 1098|   

Error: CPPCHECK_WARNING (CWE-398): [#def11]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:1127: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
# 1125|   
# 1126|   FMT_FUNC auto get_cached_power(int k) noexcept -> uint128_fallback {
# 1127|->   return cache_accessor<double>::get_cached_power(k);
# 1128|   }
# 1129|   

Error: CPPCHECK_WARNING (CWE-398): [#def12]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:1141: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
# 1139|   // Remove trailing zeros from n and return the number of zeros removed (float)
# 1140|   FMT_INLINE int remove_trailing_zeros(uint32_t& n, int s = 0) noexcept {
# 1141|->   FMT_ASSERT(n != 0, "");
# 1142|     // Modular inverse of 5 (mod 2^32): (mod_inv_5 * 5) mod 2^32 = 1.
# 1143|     constexpr uint32_t mod_inv_5 = 0xcccccccd;

Error: CPPCHECK_WARNING (CWE-398): [#def13]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:1162: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
# 1160|   // Removes trailing zeros and returns the number of zeros removed (double)
# 1161|   FMT_INLINE int remove_trailing_zeros(uint64_t& n) noexcept {
# 1162|->   FMT_ASSERT(n != 0, "");
# 1163|   
# 1164|     // This magic number is ceil(2^90 / 10^8).

Error: CPPCHECK_WARNING (CWE-398): [#def14]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:1203: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
# 1201|     decimal_fp<T> ret_value;
# 1202|     // Compute k and beta
# 1203|->   const int minus_k = floor_log10_pow2_minus_log10_4_over_3(exponent);
# 1204|     const int beta = exponent + floor_log2_pow10(-minus_k);
# 1205|   

Error: CPPCHECK_WARNING (CWE-398): [#def15]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format-inl.h:1280: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
# 1278|   
# 1279|     // Compute k and beta.
# 1280|->   const int minus_k = floor_log10_pow2(exponent) - float_info<T>::kappa;
# 1281|     const cache_entry_type cache = cache_accessor<T>::get_cached_power(-minus_k);
# 1282|     const int beta = exponent + floor_log2_pow10(-minus_k);

Error: CPPCHECK_WARNING (CWE-398): [#def16]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format.h:968: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
#  966|      */
#  967|     auto operator=(basic_memory_buffer&& other) noexcept -> basic_memory_buffer& {
#  968|->     FMT_ASSERT(this != &other, "");
#  969|       deallocate();
#  970|       move(other);

Error: CPPCHECK_WARNING (CWE-398): [#def17]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format.h:1482: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
# 1480|   // https://fmt.dev/papers/Dragonbox.pdf#page=28, section 6.1.
# 1481|   inline auto floor_log10_pow2(int e) noexcept -> int {
# 1482|->   FMT_ASSERT(e <= 2620 && e >= -2620, "too large exponent");
# 1483|     static_assert((-1 >> 1) == -1, "right shift is not arithmetic");
# 1484|     return (e * 315653) >> 20;

Error: CPPCHECK_WARNING (CWE-398): [#def18]
fmt-10.2.1-build/fmt-10.2.1/include/fmt/format.h:1488: error[throwInNoexceptFunction]: Exception thrown in function declared not to throw exceptions.
# 1486|   
# 1487|   inline auto floor_log2_pow10(int e) noexcept -> int {
# 1488|->   FMT_ASSERT(e <= 1233 && e >= -1233, "too large exponent");
# 1489|     return (e * 1741647) >> 19;
# 1490|   }

Error: COMPILER_WARNING (CWE-569): [#def19]
fmt-10.2.1-build/fmt-10.2.1/test/ostream-test.cc:30: included_from: Included from here.
fmt-10.2.1-build/fmt-10.2.1/include/fmt/ranges.h:211:49: warning[-Wtautological-compare]: self-comparison always evaluates to true
#  211 |                      integer_sequence<bool, (Is == Is)...>) -> std::true_type;
#      |                                              ~~~^~~~~
#  209|     template <std::size_t... Is>
#  210|     static auto check2(index_sequence<Is...>,
#  211|->                      integer_sequence<bool, (Is == Is)...>) -> std::true_type;
#  212|     static auto check2(...) -> std::false_type;
#  213|     template <std::size_t... Is>

Error: CPPCHECK_WARNING: [#def20]
fmt-10.2.1-build/fmt-10.2.1/src/format.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def21]
fmt-10.2.1-build/fmt-10.2.1/src/os.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def22]
fmt-10.2.1-build/fmt-10.2.1/test/chrono-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def23]
fmt-10.2.1-build/fmt-10.2.1/test/color-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def24]
fmt-10.2.1-build/fmt-10.2.1/test/compile-fp-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def25]
fmt-10.2.1-build/fmt-10.2.1/test/compile-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def26]
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def27]
fmt-10.2.1-build/fmt-10.2.1/test/enforce-checks-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def28]
fmt-10.2.1-build/fmt-10.2.1/test/format-impl-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: COMPILER_WARNING (CWE-691): [#def29]
fmt-10.2.1-build/fmt-10.2.1/test/format-impl-test.cc: scope_hint: In member function ‘virtual void format_impl_test_write_double_double_Test::TestBody()’
fmt-10.2.1-build/fmt-10.2.1/test/format-impl-test.cc:337:6: warning[-Wdangling-else]: suggest explicit braces to avoid ambiguous ‘else’
#  337 |   if (!FMT_MSC_VERSION) EXPECT_EQ(s, "42");
#      |      ^
#  335|     fmt::detail::write<char>(std::back_inserter(s), double_double(42), {});
#  336|     // Specializing is_floating_point is broken in MSVC.
#  337|->   if (!FMT_MSC_VERSION) EXPECT_EQ(s, "42");
#  338|   }
#  339|   

Error: COMPILER_WARNING (CWE-691): [#def30]
fmt-10.2.1-build/fmt-10.2.1/test/format-impl-test.cc: scope_hint: In member function ‘virtual void format_impl_test_write_dragon_even_Test::TestBody()’
fmt-10.2.1-build/fmt-10.2.1/test/format-impl-test.cc:344:6: warning[-Wdangling-else]: suggest explicit braces to avoid ambiguous ‘else’
#  344 |   if (!FMT_MSC_VERSION) EXPECT_EQ(s, "33554450");
#      |      ^
#  342|     fmt::detail::write<char>(std::back_inserter(s), slow_float(33554450.0f), {});
#  343|     // Specializing is_floating_point is broken in MSVC.
#  344|->   if (!FMT_MSC_VERSION) EXPECT_EQ(s, "33554450");
#  345|   }
#  346|   

Error: CPPCHECK_WARNING: [#def31]
fmt-10.2.1-build/fmt-10.2.1/test/format-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def32]
fmt-10.2.1-build/fmt-10.2.1/test/gtest-extra-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: COMPILER_WARNING (CWE-691): [#def33]
fmt-10.2.1-build/fmt-10.2.1/test/gtest-extra-test.cc: scope_hint: In member function ‘virtual void gtest_extra_test_expect_throw_behaves_like_single_statement_Test::TestBody()’
fmt-10.2.1-build/fmt-10.2.1/test/gtest-extra-test.cc:227:6: warning[-Wdangling-else]: suggest explicit braces to avoid ambiguous ‘else’
#  227 |   if (::testing::internal::AlwaysFalse())
#      |      ^
#  225|   
#  226|   TEST(gtest_extra_test, expect_throw_behaves_like_single_statement) {
#  227|->   if (::testing::internal::AlwaysFalse())
#  228|       EXPECT_THROW_MSG(do_nothing(), std::exception, "");
#  229|   

Error: COMPILER_WARNING (CWE-691): [#def34]
fmt-10.2.1-build/fmt-10.2.1/test/gtest-extra-test.cc: scope_hint: In member function ‘virtual void gtest_extra_test_expect_system_error_behaves_like_single_statement_Test::TestBody()’
fmt-10.2.1-build/fmt-10.2.1/test/gtest-extra-test.cc:237:6: warning[-Wdangling-else]: suggest explicit braces to avoid ambiguous ‘else’
#  237 |   if (::testing::internal::AlwaysFalse())
#      |      ^
#  235|   
#  236|   TEST(gtest_extra_test, expect_system_error_behaves_like_single_statement) {
#  237|->   if (::testing::internal::AlwaysFalse())
#  238|       EXPECT_SYSTEM_ERROR(do_nothing(), EDOM, "");
#  239|   

Error: COMPILER_WARNING (CWE-691): [#def35]
fmt-10.2.1-build/fmt-10.2.1/test/gtest-extra-test.cc: scope_hint: In member function ‘virtual void gtest_extra_test_expect_write_behaves_like_single_statement_Test::TestBody()’
fmt-10.2.1-build/fmt-10.2.1/test/gtest-extra-test.cc:247:6: warning[-Wdangling-else]: suggest explicit braces to avoid ambiguous ‘else’
#  247 |   if (::testing::internal::AlwaysFalse())
#      |      ^
#  245|   
#  246|   TEST(gtest_extra_test, expect_write_behaves_like_single_statement) {
#  247|->   if (::testing::internal::AlwaysFalse())
#  248|       EXPECT_WRITE(stdout, std::printf("x"), "x");
#  249|   

Error: CPPCHECK_WARNING: [#def36]
fmt-10.2.1-build/fmt-10.2.1/test/gtest-extra.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def37]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock-gtest-all.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING (CWE-476): [#def38]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h:11323: error[ctunullpointer]: Null pointer dereference: gmock_os
#11321|   // Defines a matcher that matches an empty container. The container must
#11322|   // support both size() and empty(), which all STL-like containers provide.
#11323|-> MATCHER(IsEmpty, negation ? "isn't empty" : "is empty") {
#11324|     if (arg.empty()) {
#11325|       return true;

Error: CPPCHECK_WARNING (CWE-476): [#def39]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h:11335: error[ctunullpointer]: Null pointer dereference: gmock_os
#11333|   // bool" operators and so can't be compared for equality with true
#11334|   // and false.
#11335|-> MATCHER(IsTrue, negation ? "is false" : "is true") {
#11336|     return static_cast<bool>(arg);
#11337|   }

Error: CPPCHECK_WARNING (CWE-476): [#def40]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h:11343: error[ctunullpointer]: Null pointer dereference: gmock_os
#11341|   // bool" operators and so can't be compared for equality with true
#11342|   // and false.
#11343|-> MATCHER(IsFalse, negation ? "is true" : "is false") {
#11344|     return !static_cast<bool>(arg);
#11345|   }

Error: COMPILER_WARNING (CWE-457): [#def41]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h:11480:61: warning[-Wmaybe-uninitialized]: ‘<anonymous>’ may be used uninitialized
#11480 |   StrictMockImpl() { ::testing::Mock::FailUninterestingCalls(this); }
#      |                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h: scope_hint: In member function ‘arg_test_custom_arg_Test::TestBody()’
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h:8659:15: note: by argument 1 of type ‘const void *’ to ‘testing::Mock::FailUninterestingCalls(void const*)’ declared here
# 8659 |   static void FailUninterestingCalls(const void* mock_obj)
#      |               ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:457:43: note: ‘<anonymous>’ declared here
#  457 |   auto&& v = testing::StrictMock<visitor>();
#      |                                           ^
#11478|   class StrictMockImpl {
#11479|    public:
#11480|->   StrictMockImpl() { ::testing::Mock::FailUninterestingCalls(this); }
#11481|   
#11482|     ~StrictMockImpl() { ::testing::Mock::UnregisterCallReaction(this); }

Error: COMPILER_WARNING (CWE-457): [#def42]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h:11480:61: warning[-Wmaybe-uninitialized]: ‘alloc’ may be used uninitialized
#11480 |   StrictMockImpl() { ::testing::Mock::FailUninterestingCalls(this); }
#      |                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h: scope_hint: In member function ‘util_test_allocator_ref_Test::TestBody()’
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h:8659:15: note: by argument 1 of type ‘const void *’ to ‘testing::Mock::FailUninterestingCalls(void const*)’ declared here
# 8659 |   static void FailUninterestingCalls(const void* mock_obj)
#      |               ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/format-test.cc:214:35: note: ‘alloc’ declared here
#  214 |   StrictMock<mock_allocator<int>> alloc;
#      |                                   ^~~~~
#11478|   class StrictMockImpl {
#11479|    public:
#11480|->   StrictMockImpl() { ::testing::Mock::FailUninterestingCalls(this); }
#11481|   
#11482|     ~StrictMockImpl() { ::testing::Mock::UnregisterCallReaction(this); }

Error: COMPILER_WARNING (CWE-457): [#def43]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h:11480:61: warning[-Wmaybe-uninitialized]: ‘visitor’ may be used uninitialized
#11480 |   StrictMockImpl() { ::testing::Mock::FailUninterestingCalls(this); }
#      |                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h: scope_hint: In member function ‘arg_test_pointer_arg_Test::TestBody()’
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gmock/gmock.h:8659:15: note: by argument 1 of type ‘const void *’ to ‘testing::Mock::FailUninterestingCalls(void const*)’ declared here
# 8659 |   static void FailUninterestingCalls(const void* mock_obj)
#      |               ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:361:59: note: ‘visitor’ declared here
#  361 |     testing::StrictMock<mock_visitor<decltype(expected)>> visitor;        \
#      |                                                           ^~~~~~~
#11478|   class StrictMockImpl {
#11479|    public:
#11480|->   StrictMockImpl() { ::testing::Mock::FailUninterestingCalls(this); }
#11481|   
#11482|     ~StrictMockImpl() { ::testing::Mock::UnregisterCallReaction(this); }

Error: COMPILER_WARNING (CWE-457): [#def44]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.224384].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘arg_test_custom_arg_Test::TestBody()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:458:23: note: ‘<anonymous>’ declared here
#  458 |   EXPECT_CALL(v, visit(_)).WillOnce(Invoke(check_custom()));
#      |                       ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def45]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.228058].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘arg_test_visit_invalid_arg_Test::TestBody()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:464:29: note: ‘<anonymous>’ declared here
#  464 |   EXPECT_CALL(visitor, visit(_));
#      |                             ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def46]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.247915].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_buffer<int>::mock_buffer(int*, unsigned long)’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:152:27: note: ‘<anonymous>’ declared here
#  152 |     ON_CALL(*this, do_grow(_)).WillByDefault(Invoke([](size_t capacity) {
#      |                           ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def47]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.248293].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_buffer<char>::mock_buffer(char*, unsigned long)’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:152:27: note: ‘<anonymous>’ declared here
#  152 |     ON_CALL(*this, do_grow(_)).WillByDefault(Invoke([](size_t capacity) {
#      |                           ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def48]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.277314].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<char>::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def49]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.279035].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<char const*>::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def50]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.280186].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<fmt::v10::basic_string_view<char> >::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def51]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.281333].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<wchar_t const*>::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def52]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.282492].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<fmt::v10::basic_string_view<wchar_t> >::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def53]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.283651].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<void const*>::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def54]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.284233].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char> >::handle>::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def55]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.285251].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:23: included_from: Included from here.
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<fmt::v10::monostate>::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def56]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.474161].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<long double>::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def57]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.475324].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<bool>::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def58]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.478813].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<float>::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: COMPILER_WARNING (CWE-457): [#def59]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6408:33: warning[-Wuninitialized]: ‘MEM[(const struct MatcherBase &)&D.482302].buffer_’ is used uninitialized
# 6408 |       : vtable_(other.vtable_), buffer_(other.buffer_) {
#      |                                 ^~~~~~~~~~~~~~~~~~~~~~
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc: scope_hint: In member function ‘mock_visitor<double>::mock_visitor()’
fmt-10.2.1-build/fmt-10.2.1/test/core-test.cc:327:25: note: ‘<anonymous>’ declared here
#  327 |     ON_CALL(*this, visit(_)).WillByDefault(Return(test_result()));
#      |                         ^
# 6406|   
# 6407|     MatcherBase(const MatcherBase& other)
# 6408|->       : vtable_(other.vtable_), buffer_(other.buffer_) {
# 6409|       if (IsShared()) buffer_.shared->Ref();
# 6410|     }

Error: CPPCHECK_WARNING (CWE-562): [#def60]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:6840: error[returnReference]: Reference to local variable returned.
# 6838|     template <typename T>
# 6839|     static const T& Unwrap(std::reference_wrapper<T> v) {
# 6840|->     return v;
# 6841|     }
# 6842|   

Error: CPPCHECK_WARNING (CWE-664): [#def61]
fmt-10.2.1-build/fmt-10.2.1/test/gtest/gtest/gtest.h:8106: error[mismatchingContainers]: Iterators of different containers 'impl_' and 'other.impl_' are used together.
# 8104|     }
# 8105|     bool operator==(const ParamIterator& other) const {
# 8106|->     return impl_.get() == other.impl_.get() || impl_->Equals(*other.impl_);
# 8107|     }
# 8108|     bool operator!=(const ParamIterator& other) const {

Error: CPPCHECK_WARNING: [#def62]
fmt-10.2.1-build/fmt-10.2.1/test/header-only-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def63]
fmt-10.2.1-build/fmt-10.2.1/test/os-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def64]
fmt-10.2.1-build/fmt-10.2.1/test/ostream-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def65]
fmt-10.2.1-build/fmt-10.2.1/test/posix-mock-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def66]
fmt-10.2.1-build/fmt-10.2.1/test/printf-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def67]
fmt-10.2.1-build/fmt-10.2.1/test/ranges-odr-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def68]
fmt-10.2.1-build/fmt-10.2.1/test/ranges-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def69]
fmt-10.2.1-build/fmt-10.2.1/test/scan-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING (CWE-562): [#def70]
fmt-10.2.1-build/fmt-10.2.1/test/scan.h:90: error[returnReference]: Reference to local variable returned.
#   88|       }
#   89|   
#   90|->     friend scan_buffer& get_buffer(iterator it) { return *it.buf_; }
#   91|   
#   92|      public:

Error: CPPCHECK_WARNING: [#def71]
fmt-10.2.1-build/fmt-10.2.1/test/std-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def72]
fmt-10.2.1-build/fmt-10.2.1/test/unicode-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def73]
fmt-10.2.1-build/fmt-10.2.1/test/util.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Error: CPPCHECK_WARNING: [#def74]
fmt-10.2.1-build/fmt-10.2.1/test/xchar-test.cc: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.

Scan Properties

analyzer-version-clang18.1.7
analyzer-version-cppcheck2.14.2
analyzer-version-gcc14.1.1
analyzer-version-gcc-analyzer14.1.1
analyzer-version-shellcheck0.10.0
enabled-pluginsclang, cppcheck, gcc, shellcheck
exit-code0
hostip-172-16-1-13.us-west-2.compute.internal
mock-configfedora-41-x86_64
project-namefmt-10.2.1-4.fc41
store-results-to/tmp/tmpbhqn15fb/fmt-10.2.1-4.fc41.tar.xz
time-created2024-07-03 12:40:16
time-finished2024-07-03 12:44:08
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-41-x86_64' '-t' 'cppcheck,gcc,clang,shellcheck' '-o' '/tmp/tmpbhqn15fb/fmt-10.2.1-4.fc41.tar.xz' '--gcc-analyze' '/tmp/tmpbhqn15fb/fmt-10.2.1-4.fc41.src.rpm'
tool-versioncsmock-3.5.3-1.el9