[Libreoffice-commits] core.git: i18nutil/source

Michael Stahl mstahl at redhat.com
Mon May 29 15:10:27 UTC 2017


 i18nutil/source/utility/paper.cxx |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit 922e935c8812b1c1f94347bdbd7cdf277a75644e
Author: Michael Stahl <mstahl at redhat.com>
Date:   Mon May 29 17:08:06 2017 +0200

    i18nutil: fix invalid string copy that prevents startup
    
    (regression from ef513fd4b049b214a03fbe6e62a5ea43680a7a9b)
    
    Change-Id: Ia3ba5ba853648a4b180d6cc2318a4780fc87bf4d

diff --git a/i18nutil/source/utility/paper.cxx b/i18nutil/source/utility/paper.cxx
index 657496abcc44..7e250024ebe4 100644
--- a/i18nutil/source/utility/paper.cxx
+++ b/i18nutil/source/utility/paper.cxx
@@ -271,9 +271,10 @@ PaperInfo PaperInfo::getSystemDefaultPaper()
 
                 if (ePaper == PAPER_USER)
                 {
-                    bHalve = !aPaper.startsWith("half");
-                    if (bHalve)
+                    if (aPaper.startsWith("half"))
+                    {
                         aPaper = aPaper.copy(4);
+                    }
                     ePaper = PaperInfo::fromPSName(aPaper);
                 }
 


More information about the Libreoffice-commits mailing list