[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-2-0' - wsd/SenderQueue.hpp

Ashod Nakashian ashod.nakashian at collabora.co.uk
Mon Dec 19 13:06:20 UTC 2016


 wsd/SenderQueue.hpp |   12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

New commits:
commit 993fd0bd0866b33441722a85fa54b124e98af30f
Author: Ashod Nakashian <ashod.nakashian at collabora.co.uk>
Date:   Mon Dec 19 08:04:59 2016 -0500

    wsd: fix compiler warnings of shadowing variables
    
    Change-Id: I3a1344d58b1af11c95accb5f7a9d1c8e5b2d19fb
    Reviewed-on: https://gerrit.libreoffice.org/32180
    Reviewed-by: Andras Timar <andras.timar at collabora.com>
    Tested-by: Andras Timar <andras.timar at collabora.com>

diff --git a/wsd/SenderQueue.hpp b/wsd/SenderQueue.hpp
index 44742ab..e61fbde 100644
--- a/wsd/SenderQueue.hpp
+++ b/wsd/SenderQueue.hpp
@@ -63,10 +63,10 @@ public:
 
     /// Construct a message from a character array with type.
     /// data must be include the full first-line.
-    MessagePayload(const char* data,
-                   const size_t size,
+    MessagePayload(const char* p,
+                   const size_t len,
                    const enum Type type) :
-        _data(data, data + size),
+        _data(p, p + len),
         _tokens(LOOLProtocol::tokenize(_data.data(), _data.size())),
         _firstLine(LOOLProtocol::getFirstLine(_data.data(), _data.size())),
         _abbreviation(LOOLProtocol::getAbbreviatedMessage(_data.data(), _data.size())),
@@ -95,11 +95,11 @@ public:
     }
 
     /// Append more data to the message.
-    void append(const char* data, const size_t size)
+    void append(const char* p, const size_t len)
     {
         const auto curSize = _data.size();
-        _data.resize(curSize + size);
-        std::memcpy(_data.data() + curSize, data, size);
+        _data.resize(curSize + len);
+        std::memcpy(_data.data() + curSize, p, len);
     }
 
     /// Returns true if and only if the payload is considered Binary.


More information about the Libreoffice-commits mailing list