aboutsummaryrefslogtreecommitdiffstats
path: root/common/rfb
diff options
context:
space:
mode:
authorPierre Ossman <ossman@cendio.se>2020-05-15 23:33:02 +0200
committerPierre Ossman <ossman@cendio.se>2020-05-21 11:34:22 +0200
commitdc38699af81e8bb953946000121f0a48cf30b962 (patch)
tree150d4d635a370a6a2aed869d8aa9226c6b3da298 /common/rfb
parent5e875ba492944b80ad43cd4fbdedd2a6d2fd56d0 (diff)
downloadtigervnc-dc38699af81e8bb953946000121f0a48cf30b962.tar.gz
tigervnc-dc38699af81e8bb953946000121f0a48cf30b962.zip
Remove OutStream::skip()
It might leak data depending on what's in the buffer. Use pad() instead where blank space is needed.
Diffstat (limited to 'common/rfb')
-rw-r--r--common/rfb/CMsgWriter.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/common/rfb/CMsgWriter.cxx b/common/rfb/CMsgWriter.cxx
index 3180391b..c452f5eb 100644
--- a/common/rfb/CMsgWriter.cxx
+++ b/common/rfb/CMsgWriter.cxx
@@ -61,7 +61,7 @@ void CMsgWriter::writeSetEncodings(const std::list<rdr::U32> encodings)
{
std::list<rdr::U32>::const_iterator iter;
startMsg(msgTypeSetEncodings);
- os->skip(1);
+ os->pad(1);
os->writeU16(encodings.size());
for (iter = encodings.begin(); iter != encodings.end(); ++iter)
os->writeU32(*iter);