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

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Wed Oct 9 12:05:55 UTC 2019


 comphelper/source/misc/backupfilehelper.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 728de28b8b7f334fd2102e132539a059d6a0a66f
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Wed Oct 9 09:19:18 2019 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Wed Oct 9 14:04:30 2019 +0200

    cid#1448412 subvert Untrusted value as argument
    
    Change-Id: If2a2ed737c1807250550e3bb3a768807df08a5c1
    Reviewed-on: https://gerrit.libreoffice.org/80522
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/comphelper/source/misc/backupfilehelper.cxx b/comphelper/source/misc/backupfilehelper.cxx
index 97c1e9d109d6..749b9896cb0b 100644
--- a/comphelper/source/misc/backupfilehelper.cxx
+++ b/comphelper/source/misc/backupfilehelper.cxx
@@ -160,7 +160,7 @@ namespace
         // read rTarget
         if (osl::File::E_None == rFile->read(static_cast<void*>(aTarget.data()), nLength, nBaseRead) && nLength == nBaseRead)
         {
-            rTarget = OString(aTarget.data(), static_cast< sal_Int32 >(nLength));
+            rTarget = OString(aTarget.data(), static_cast<sal_Int32>(nBaseRead));
             return true;
         }
 


More information about the Libreoffice-commits mailing list