commit b4a982e0229ea953d458a495e56e7362c6a3b78b
Author: Jean-Marc Lasgouttes <[email protected]>
Date: Thu Feb 13 11:57:11 2025 +0100
avoid temporary variables (spotted by Coverity Scan)
---
src/LyXRC.cpp | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/src/LyXRC.cpp b/src/LyXRC.cpp
index 4309fc41d4..966b2ce410 100644
--- a/src/LyXRC.cpp
+++ b/src/LyXRC.cpp
@@ -958,16 +958,14 @@ LyXRC::ReturnValues LyXRC::read(Lexer & lexrc, bool
check_format)
case RC_VIEWER_ALTERNATIVES: {
string format, command;
if ((lexrc >> format) && lexrc.next(true)) {
- command = lexrc.getString();
- viewer_alternatives[format].insert(command);
+
viewer_alternatives[format].insert(lexrc.getString());
}
break;
}
case RC_EDITOR_ALTERNATIVES: {
string format, command;
if ((lexrc >> format) && lexrc.next(true)) {
- command = lexrc.getString();
- editor_alternatives[format].insert(command);
+
editor_alternatives[format].insert(lexrc.getString());
}
break;
}
--
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs