commit 1242365de7b7f61dd4aaacce66ab40a3cda144bf
Author: Jean-Marc Lasgouttes <[email protected]>
Date:   Sat Sep 20 21:56:17 2025 +0200

    readTheme() : pass rc parameter by address.
    
    This issue has been pointed out by Coverity Scan as a performance issue.
    
    However, it turns out that it is necessary to pass rc by address so
    that it can be modified.
---
 src/frontends/qt/GuiPrefs.cpp | 2 +-
 src/frontends/qt/GuiPrefs.h   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/frontends/qt/GuiPrefs.cpp b/src/frontends/qt/GuiPrefs.cpp
index f055a65078..eb961e290b 100644
--- a/src/frontends/qt/GuiPrefs.cpp
+++ b/src/frontends/qt/GuiPrefs.cpp
@@ -1614,7 +1614,7 @@ void PrefColors::cacheAllThemes()
 }
 
 
-ColorNamePairs PrefColors::readTheme(FileName fullpath, LyXRC rc) const
+ColorNamePairs PrefColors::readTheme(FileName const & fullpath, LyXRC & rc) 
const
 {
        ColorNamePairs colors;
        colors.resize(lcolors_.size());
diff --git a/src/frontends/qt/GuiPrefs.h b/src/frontends/qt/GuiPrefs.h
index 4dc44d64ec..ab67f69ebc 100644
--- a/src/frontends/qt/GuiPrefs.h
+++ b/src/frontends/qt/GuiPrefs.h
@@ -351,7 +351,7 @@ private:
        ///
        void cacheAllThemes();
        ///
-       ColorNamePairs readTheme(support::FileName fullpath, LyXRC rc) const;
+       ColorNamePairs readTheme(support::FileName const & fullpath, LyXRC & 
rc) const;
        /// Common algorithm between saving and exporting
        void saveExportThemeCommon(QString file_path);
        /// Common algorithm between loading and importing.
-- 
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs

Reply via email to