[Libreoffice-commits] online.git: wsd/SenderQueue.hpp
Ashod Nakashian
ashod.nakashian at collabora.co.uk
Mon Dec 19 13:19:11 UTC 2016
wsd/SenderQueue.hpp | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
New commits:
commit 200bf6f92be6d913c8fb9a88d2249c00257059c8
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>
Reviewed-on: https://gerrit.libreoffice.org/32181
Reviewed-by: Ashod Nakashian <ashnakash at gmail.com>
Tested-by: Ashod Nakashian <ashnakash at gmail.com>
diff --git a/wsd/SenderQueue.hpp b/wsd/SenderQueue.hpp
index fd452bf..6083c19 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