New Defects reported by Coverity Scan for LibreOffice

scan-admin at coverity.com scan-admin at coverity.com
Wed Sep 25 05:49:50 UTC 2024


Hi,

Please find the latest report on new defect(s) introduced to LibreOffice found with Coverity Scan.

2 new defect(s) introduced to LibreOffice found with Coverity Scan.
29 defect(s), reported by Coverity Scan earlier, were marked fixed in the recent build analyzed by Coverity Scan.

New defect(s) Reported-by: Coverity Scan
Showing 2 of 2 defect(s)


** CID 1619687:    (STREAM_FORMAT_STATE)
/unotest/source/cpp/unoexceptionprotector/unoexceptionprotector.cxx: 150 in <unnamed>::printUnoValue(std::basic_ostream<char, std::char_traits<char>>&, const com::sun::star::uno::Reference<com::sun::star::reflection::XIdlReflection> &, const com::sun::star::uno::Type &, const com::sun::star::uno::Any &)()
/unotest/source/cpp/unoexceptionprotector/unoexceptionprotector.cxx: 150 in <unnamed>::printUnoValue(std::basic_ostream<char, std::char_traits<char>>&, const com::sun::star::uno::Reference<com::sun::star::reflection::XIdlReflection> &, const com::sun::star::uno::Type &, const com::sun::star::uno::Any &)()
/unotest/source/cpp/unoexceptionprotector/unoexceptionprotector.cxx: 150 in <unnamed>::printUnoValue(std::basic_ostream<char, std::char_traits<char>>&, const com::sun::star::uno::Reference<com::sun::star::reflection::XIdlReflection> &, const com::sun::star::uno::Type &, const com::sun::star::uno::Any &)()


________________________________________________________________________________________________________
*** CID 1619687:    (STREAM_FORMAT_STATE)
/unotest/source/cpp/unoexceptionprotector/unoexceptionprotector.cxx: 150 in <unnamed>::printUnoValue(std::basic_ostream<char, std::char_traits<char>>&, const com::sun::star::uno::Reference<com::sun::star::reflection::XIdlReflection> &, const com::sun::star::uno::Type &, const com::sun::star::uno::Any &)()
144         case css::uno::TypeClass_INTERFACE:
145             out << '@' << value.getValue();
146             break;
147         default:
148             O3TL_UNREACHABLE;
149         }
>>>     CID 1619687:    (STREAM_FORMAT_STATE)
>>>     Changing format state of stream "out" for category uppercase without later restoring it.
150     }
151     
152     class Prot : public CppUnit::Protector
153     {
154     public:
155         Prot() {}
/unotest/source/cpp/unoexceptionprotector/unoexceptionprotector.cxx: 150 in <unnamed>::printUnoValue(std::basic_ostream<char, std::char_traits<char>>&, const com::sun::star::uno::Reference<com::sun::star::reflection::XIdlReflection> &, const com::sun::star::uno::Type &, const com::sun::star::uno::Any &)()
144         case css::uno::TypeClass_INTERFACE:
145             out << '@' << value.getValue();
146             break;
147         default:
148             O3TL_UNREACHABLE;
149         }
>>>     CID 1619687:    (STREAM_FORMAT_STATE)
>>>     Changing format state of stream "out" for category uppercase without later restoring it.
150     }
151     
152     class Prot : public CppUnit::Protector
153     {
154     public:
155         Prot() {}
/unotest/source/cpp/unoexceptionprotector/unoexceptionprotector.cxx: 150 in <unnamed>::printUnoValue(std::basic_ostream<char, std::char_traits<char>>&, const com::sun::star::uno::Reference<com::sun::star::reflection::XIdlReflection> &, const com::sun::star::uno::Type &, const com::sun::star::uno::Any &)()
144         case css::uno::TypeClass_INTERFACE:
145             out << '@' << value.getValue();
146             break;
147         default:
148             O3TL_UNREACHABLE;
149         }
>>>     CID 1619687:    (STREAM_FORMAT_STATE)
>>>     Changing format state of stream "out" for categories uppercase, fill without later restoring it.
150     }
151     
152     class Prot : public CppUnit::Protector
153     {
154     public:
155         Prot() {}

** CID 1619686:    (MISMATCHED_ITERATOR)
/sd/source/ui/unoidl/unomodel.cxx: 551 in <unnamed>::convertEnum<short, (unsigned long)15>(rtl::OStringBuffer &, T1, const frozen::unordered_map<T1, std::basic_string_view<char, std::char_traits<char>>, T2, frozen::elsa<T1>, std::equal_to<T1>> &)()
/sd/source/ui/unoidl/unomodel.cxx: 551 in <unnamed>::convertEnum<short, (unsigned long)13>(rtl::OStringBuffer &, T1, const frozen::unordered_map<T1, std::basic_string_view<char, std::char_traits<char>>, T2, frozen::elsa<T1>, std::equal_to<T1>> &)()
/sd/source/ui/unoidl/unomodel.cxx: 551 in <unnamed>::convertEnum<short, (unsigned long)7>(rtl::OStringBuffer &, T1, const frozen::unordered_map<T1, std::basic_string_view<char, std::char_traits<char>>, T2, frozen::elsa<T1>, std::equal_to<T1>> &)()
/sd/source/ui/unoidl/unomodel.cxx: 551 in <unnamed>::convertEnum<short, (unsigned long)27>(rtl::OStringBuffer &, T1, const frozen::unordered_map<T1, std::basic_string_view<char, std::char_traits<char>>, T2, frozen::elsa<T1>, std::equal_to<T1>> &)()
/sd/source/ui/unoidl/unomodel.cxx: 551 in <unnamed>::convertEnum<short, (unsigned long)5>(rtl::OStringBuffer &, T1, const frozen::unordered_map<T1, std::basic_string_view<char, std::char_traits<char>>, T2, frozen::elsa<T1>, std::equal_to<T1>> &)()


________________________________________________________________________________________________________
*** CID 1619686:    (MISMATCHED_ITERATOR)
/sd/source/ui/unoidl/unomodel.cxx: 551 in <unnamed>::convertEnum<short, (unsigned long)15>(rtl::OStringBuffer &, T1, const frozen::unordered_map<T1, std::basic_string_view<char, std::char_traits<char>>, T2, frozen::elsa<T1>, std::equal_to<T1>> &)()
545     
546     template <typename EnumT, size_t N>
547     constexpr bool convertEnum(OStringBuffer& rBuffer, EnumT nValue,
548                                const frozen::unordered_map<EnumT, std::string_view, N>& rMap)
549     {
550         auto iterator = rMap.find(nValue);
>>>     CID 1619686:    (MISMATCHED_ITERATOR)
>>>     Comparing "iterator" from "rMap" to "<unnamed>::constAnimationNodeTypeToString.end()" from "<unnamed>::constAnimationNodeTypeToString".
551         if (iterator == constAnimationNodeTypeToString.end())
552             return false;
553         rBuffer.append(iterator->second);
554         return true;
555     }
556     
/sd/source/ui/unoidl/unomodel.cxx: 551 in <unnamed>::convertEnum<short, (unsigned long)13>(rtl::OStringBuffer &, T1, const frozen::unordered_map<T1, std::basic_string_view<char, std::char_traits<char>>, T2, frozen::elsa<T1>, std::equal_to<T1>> &)()
545     
546     template <typename EnumT, size_t N>
547     constexpr bool convertEnum(OStringBuffer& rBuffer, EnumT nValue,
548                                const frozen::unordered_map<EnumT, std::string_view, N>& rMap)
549     {
550         auto iterator = rMap.find(nValue);
>>>     CID 1619686:    (MISMATCHED_ITERATOR)
>>>     Comparing "iterator" from "rMap" to "<unnamed>::constAnimationNodeTypeToString.end()" from "<unnamed>::constAnimationNodeTypeToString".
551         if (iterator == constAnimationNodeTypeToString.end())
552             return false;
553         rBuffer.append(iterator->second);
554         return true;
555     }
556     
/sd/source/ui/unoidl/unomodel.cxx: 551 in <unnamed>::convertEnum<short, (unsigned long)7>(rtl::OStringBuffer &, T1, const frozen::unordered_map<T1, std::basic_string_view<char, std::char_traits<char>>, T2, frozen::elsa<T1>, std::equal_to<T1>> &)()
545     
546     template <typename EnumT, size_t N>
547     constexpr bool convertEnum(OStringBuffer& rBuffer, EnumT nValue,
548                                const frozen::unordered_map<EnumT, std::string_view, N>& rMap)
549     {
550         auto iterator = rMap.find(nValue);
>>>     CID 1619686:    (MISMATCHED_ITERATOR)
>>>     Comparing "iterator" from "rMap" to "<unnamed>::constAnimationNodeTypeToString.end()" from "<unnamed>::constAnimationNodeTypeToString".
551         if (iterator == constAnimationNodeTypeToString.end())
552             return false;
553         rBuffer.append(iterator->second);
554         return true;
555     }
556     
/sd/source/ui/unoidl/unomodel.cxx: 551 in <unnamed>::convertEnum<short, (unsigned long)27>(rtl::OStringBuffer &, T1, const frozen::unordered_map<T1, std::basic_string_view<char, std::char_traits<char>>, T2, frozen::elsa<T1>, std::equal_to<T1>> &)()
545     
546     template <typename EnumT, size_t N>
547     constexpr bool convertEnum(OStringBuffer& rBuffer, EnumT nValue,
548                                const frozen::unordered_map<EnumT, std::string_view, N>& rMap)
549     {
550         auto iterator = rMap.find(nValue);
>>>     CID 1619686:    (MISMATCHED_ITERATOR)
>>>     Comparing "iterator" from "rMap" to "<unnamed>::constAnimationNodeTypeToString.end()" from "<unnamed>::constAnimationNodeTypeToString".
551         if (iterator == constAnimationNodeTypeToString.end())
552             return false;
553         rBuffer.append(iterator->second);
554         return true;
555     }
556     
/sd/source/ui/unoidl/unomodel.cxx: 551 in <unnamed>::convertEnum<short, (unsigned long)5>(rtl::OStringBuffer &, T1, const frozen::unordered_map<T1, std::basic_string_view<char, std::char_traits<char>>, T2, frozen::elsa<T1>, std::equal_to<T1>> &)()
545     
546     template <typename EnumT, size_t N>
547     constexpr bool convertEnum(OStringBuffer& rBuffer, EnumT nValue,
548                                const frozen::unordered_map<EnumT, std::string_view, N>& rMap)
549     {
550         auto iterator = rMap.find(nValue);
>>>     CID 1619686:    (MISMATCHED_ITERATOR)
>>>     Comparing "iterator" from "rMap" to "<unnamed>::constAnimationNodeTypeToString.end()" from "<unnamed>::constAnimationNodeTypeToString".
551         if (iterator == constAnimationNodeTypeToString.end())
552             return false;
553         rBuffer.append(iterator->second);
554         return true;
555     }
556     


________________________________________________________________________________________________________
To view the defects in Coverity Scan visit, https://u15810271.ct.sendgrid.net/ls/click?upn=u001.AxU2LYlgjL6eX23u9ErQy-2BKADyCpvUKOL6EWmZljiu6VvXBlQRUbS683tC8265rGNPXqJ1ffcoLZCnTuJFQbNcTEkb4XaEQkzovKhJ5DB3c-3DmlSt_A9M4dSy7guk8NP6DcfgslOyvJRzavztVIKj6nRqYjYpWom7SJFyX0y710bz0kUGtVHHxeD5BxAYEYTJ8zW3eo9tz2SWZQlxxIJyNCXRErIFEqRy24QK6ic9cZXI3jh4eH79xefEu8FqNiUjnaT7KpkRYhtvMT4N7cQ4YAYQw-2By6sZ6hrcsL9W-2FlDHmFBuQg9doVN79oNqusVmkVFRpx8Utlcka2NBxFjNLKX-2FhFpu90-3D



More information about the LibreOffice mailing list