commit c43e019fd3e966b7377fa11a8a6f0b071b355c47
Author: Jean-Marc Lasgouttes <[email protected]>
Date:   Sun Nov 23 15:27:39 2025 +0100

    Rewrite code to please Coverity Scan
---
 src/Converter.cpp | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/Converter.cpp b/src/Converter.cpp
index c4381e864a..03172ac2ae 100644
--- a/src/Converter.cpp
+++ b/src/Converter.cpp
@@ -264,10 +264,10 @@ void Converters::update(Formats const & formats)
 // It is called when adding a new converter in FormPreferences
 void Converters::updateLast(Formats const & formats)
 {
-       if (converterlist_.begin() != converterlist_.end()) {
-               ConverterList::iterator it = converterlist_.end() - 1;
-               it->setFrom(formats.getFormat(it->from()));
-               it->setTo(formats.getFormat(it->to()));
+       if (!converterlist_.empty()) {
+               auto & last = converterlist_.back();
+               last.setFrom(formats.getFormat(last.from()));
+               last.setTo(formats.getFormat(last.to()));
        }
 }
 
-- 
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs

Reply via email to