commit e744b18b76a0eece95a8850a473da636a42a2a59
Author: Jean-Marc Lasgouttes <[email protected]>
Date:   Fri Nov 28 17:50:35 2025 +0100

    Pass docstring argument by reference
    
    Spotted by Coverity Scan.
---
 src/mathed/MathStream.cpp | 2 +-
 src/mathed/MathStream.h   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/mathed/MathStream.cpp b/src/mathed/MathStream.cpp
index 6711e821d4..318042184c 100644
--- a/src/mathed/MathStream.cpp
+++ b/src/mathed/MathStream.cpp
@@ -440,7 +440,7 @@ TeXMathStream & operator<<(TeXMathStream & ws, docstring 
const & s)
 
 TeXMathStream::TeXMathStream(otexrowstream & os, bool fragile, bool latex,
                             OutputType output, Encoding const * encoding,
-                            docstring escapechars)
+                            docstring const & escapechars)
        : os_(os), fragile_(fragile), latex_(latex),
          output_(output), encoding_(encoding), escape_chars_(escapechars)
 {}
diff --git a/src/mathed/MathStream.h b/src/mathed/MathStream.h
index 73dd05ea50..5bb5cceaf8 100644
--- a/src/mathed/MathStream.h
+++ b/src/mathed/MathStream.h
@@ -147,7 +147,7 @@ public:
        explicit TeXMathStream(otexrowstream & os, bool fragile = false,
                               bool latex = false, OutputType output = 
wsDefault,
                               Encoding const * encoding = nullptr,
-                              docstring escapechar = docstring());
+                              docstring const & escapechar = docstring());
        ///
        ~TeXMathStream();
        ///
-- 
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs

Reply via email to