aboutsummaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/network/Socket.cxx4
-rw-r--r--common/network/TcpSocket.cxx4
-rw-r--r--common/network/UnixSocket.cxx4
-rw-r--r--common/os/Mutex.cxx4
-rw-r--r--common/rdr/AESInStream.cxx12
-rw-r--r--common/rdr/BufferedOutStream.cxx4
-rw-r--r--common/rdr/Exception.cxx4
-rw-r--r--common/rfb/CConnection.cxx4
-rw-r--r--common/rfb/CMsgReader.cxx12
-rw-r--r--common/rfb/CSecurityDH.cxx4
-rw-r--r--common/rfb/CSecurityMSLogonII.cxx4
-rw-r--r--common/rfb/CSecurityNone.h2
-rw-r--r--common/rfb/CSecurityPlain.h2
-rw-r--r--common/rfb/CSecurityRSAAES.cxx4
-rw-r--r--common/rfb/CSecurityStack.cxx4
-rw-r--r--common/rfb/CSecurityTLS.cxx4
-rw-r--r--common/rfb/CSecurityVeNCrypt.cxx5
-rw-r--r--common/rfb/CSecurityVncAuth.h2
-rw-r--r--common/rfb/Configuration.cxx6
-rw-r--r--common/rfb/Cursor.cxx6
-rw-r--r--common/rfb/DecodeManager.cxx11
-rw-r--r--common/rfb/Decoder.cxx2
-rw-r--r--common/rfb/H264Decoder.cxx10
-rw-r--r--common/rfb/H264WinDecoderContext.cxx20
-rw-r--r--common/rfb/HextileDecoder.cxx4
-rw-r--r--common/rfb/HextileEncoder.cxx4
-rw-r--r--common/rfb/RREEncoder.cxx4
-rw-r--r--common/rfb/RawEncoder.cxx4
-rw-r--r--common/rfb/SConnection.cxx8
-rw-r--r--common/rfb/SSecurityNone.h2
-rw-r--r--common/rfb/SSecurityPlain.cxx2
-rw-r--r--common/rfb/SSecurityRSAAES.cxx4
-rw-r--r--common/rfb/SSecurityStack.cxx4
-rw-r--r--common/rfb/SSecurityTLS.cxx4
-rw-r--r--common/rfb/SSecurityVeNCrypt.cxx5
-rw-r--r--common/rfb/SSecurityVncAuth.cxx8
-rw-r--r--common/rfb/TightEncoder.cxx4
-rw-r--r--common/rfb/TightJPEGEncoder.cxx4
-rw-r--r--common/rfb/VNCServerST.cxx4
-rw-r--r--common/rfb/ZRLEEncoder.cxx4
40 files changed, 105 insertions, 102 deletions
diff --git a/common/network/Socket.cxx b/common/network/Socket.cxx
index 971a7170..8da44366 100644
--- a/common/network/Socket.cxx
+++ b/common/network/Socket.cxx
@@ -128,8 +128,8 @@ void Socket::setFd(int fd)
isShutdown_ = false;
}
-SocketListener::SocketListener(int fd)
- : fd(fd), filter(nullptr)
+SocketListener::SocketListener(int fd_)
+ : fd(fd_), filter(nullptr)
{
initSockets();
}
diff --git a/common/network/TcpSocket.cxx b/common/network/TcpSocket.cxx
index d9b376c9..3f2f0f1f 100644
--- a/common/network/TcpSocket.cxx
+++ b/common/network/TcpSocket.cxx
@@ -338,8 +338,8 @@ TcpListener::TcpListener(const struct sockaddr *listenaddr,
listen(sock);
}
-Socket* TcpListener::createSocket(int fd) {
- return new TcpSocket(fd);
+Socket* TcpListener::createSocket(int fd_) {
+ return new TcpSocket(fd_);
}
std::list<std::string> TcpListener::getMyAddresses() {
diff --git a/common/network/UnixSocket.cxx b/common/network/UnixSocket.cxx
index e7793849..3a422b6c 100644
--- a/common/network/UnixSocket.cxx
+++ b/common/network/UnixSocket.cxx
@@ -157,8 +157,8 @@ UnixListener::~UnixListener()
unlink(addr.sun_path);
}
-Socket* UnixListener::createSocket(int fd) {
- return new UnixSocket(fd);
+Socket* UnixListener::createSocket(int fd_) {
+ return new UnixSocket(fd_);
}
int UnixListener::getMyPort() {
diff --git a/common/os/Mutex.cxx b/common/os/Mutex.cxx
index 5e245a6d..2a768b4c 100644
--- a/common/os/Mutex.cxx
+++ b/common/os/Mutex.cxx
@@ -84,9 +84,9 @@ void Mutex::unlock()
#endif
}
-Condition::Condition(Mutex* mutex)
+Condition::Condition(Mutex* mutex_)
{
- this->mutex = mutex;
+ this->mutex = mutex_;
#ifdef WIN32
systemCondition = new CONDITION_VARIABLE;
diff --git a/common/rdr/AESInStream.cxx b/common/rdr/AESInStream.cxx
index de91a3df..d6d944a3 100644
--- a/common/rdr/AESInStream.cxx
+++ b/common/rdr/AESInStream.cxx
@@ -45,15 +45,15 @@ bool AESInStream::fillBuffer()
{
if (!in->hasData(2))
return false;
- const uint8_t* ptr = in->getptr(2);
- size_t length = ((int)ptr[0] << 8) | (int)ptr[1];
+ const uint8_t* buf = in->getptr(2);
+ size_t length = ((int)buf[0] << 8) | (int)buf[1];
if (!in->hasData(2 + length + 16))
return false;
ensureSpace(length);
- ptr = in->getptr(2 + length + 16);
- const uint8_t* ad = ptr;
- const uint8_t* data = ptr + 2;
- const uint8_t* mac = ptr + 2 + length;
+ buf = in->getptr(2 + length + 16);
+ const uint8_t* ad = buf;
+ const uint8_t* data = buf + 2;
+ const uint8_t* mac = buf + 2 + length;
uint8_t macComputed[16];
if (keySize == 128) {
diff --git a/common/rdr/BufferedOutStream.cxx b/common/rdr/BufferedOutStream.cxx
index 0ee3d644..0d6a1eb6 100644
--- a/common/rdr/BufferedOutStream.cxx
+++ b/common/rdr/BufferedOutStream.cxx
@@ -31,8 +31,8 @@ using namespace rdr;
static const size_t DEFAULT_BUF_SIZE = 16384;
static const size_t MAX_BUF_SIZE = 32 * 1024 * 1024;
-BufferedOutStream::BufferedOutStream(bool emulateCork)
- : bufSize(DEFAULT_BUF_SIZE), offset(0), emulateCork(emulateCork)
+BufferedOutStream::BufferedOutStream(bool emulateCork_)
+ : bufSize(DEFAULT_BUF_SIZE), offset(0), emulateCork(emulateCork_)
{
ptr = start = sentUpTo = new uint8_t[bufSize];
end = start + bufSize;
diff --git a/common/rdr/Exception.cxx b/common/rdr/Exception.cxx
index f5ad1819..d5546274 100644
--- a/common/rdr/Exception.cxx
+++ b/common/rdr/Exception.cxx
@@ -51,8 +51,8 @@ Exception::Exception(const char *format, ...) {
va_end(ap);
}
-GAIException::GAIException(const char* s, int err)
- : Exception("%s", s)
+GAIException::GAIException(const char* s, int err_)
+ : Exception("%s", s), err(err_)
{
strncat(str_, ": ", len-1-strlen(str_));
#ifdef _WIN32
diff --git a/common/rfb/CConnection.cxx b/common/rfb/CConnection.cxx
index 212671aa..0db5f4c8 100644
--- a/common/rfb/CConnection.cxx
+++ b/common/rfb/CConnection.cxx
@@ -675,7 +675,7 @@ void CConnection::sendClipboardData(const char* data)
// FIXME: This conversion magic should be in CMsgWriter
std::string filtered(convertCRLF(data));
size_t sizes[1] = { filtered.size() + 1 };
- const uint8_t* data[1] = { (const uint8_t*)filtered.c_str() };
+ const uint8_t* datas[1] = { (const uint8_t*)filtered.c_str() };
if (unsolicitedClipboardAttempt) {
unsolicitedClipboardAttempt = false;
@@ -687,7 +687,7 @@ void CConnection::sendClipboardData(const char* data)
}
}
- writer()->writeClipboardProvide(rfb::clipboardUTF8, sizes, data);
+ writer()->writeClipboardProvide(rfb::clipboardUTF8, sizes, datas);
} else {
writer()->writeClientCutText(data);
}
diff --git a/common/rfb/CMsgReader.cxx b/common/rfb/CMsgReader.cxx
index c10b7033..8bcdbfd0 100644
--- a/common/rfb/CMsgReader.cxx
+++ b/common/rfb/CMsgReader.cxx
@@ -827,31 +827,31 @@ bool CMsgReader::readExtendedDesktopSize(int x, int y, int w, int h)
bool CMsgReader::readLEDState()
{
- uint8_t state;
+ uint8_t ledState;
if (!is->hasData(1))
return false;
- state = is->readU8();
+ ledState = is->readU8();
- handler->setLEDState(state);
+ handler->setLEDState(ledState);
return true;
}
bool CMsgReader::readVMwareLEDState()
{
- uint32_t state;
+ uint32_t ledState;
if (!is->hasData(4))
return false;
- state = is->readU32();
+ ledState = is->readU32();
// As luck has it, this extension uses the same bit definitions,
// so no conversion required
- handler->setLEDState(state);
+ handler->setLEDState(ledState);
return true;
}
diff --git a/common/rfb/CSecurityDH.cxx b/common/rfb/CSecurityDH.cxx
index f6e5ded4..6d9650bd 100644
--- a/common/rfb/CSecurityDH.cxx
+++ b/common/rfb/CSecurityDH.cxx
@@ -47,8 +47,8 @@ using namespace rfb;
const int MinKeyLength = 128;
const int MaxKeyLength = 1024;
-CSecurityDH::CSecurityDH(CConnection* cc)
- : CSecurity(cc), keyLength(0)
+CSecurityDH::CSecurityDH(CConnection* cc_)
+ : CSecurity(cc_), keyLength(0)
{
mpz_init(g);
mpz_init(p);
diff --git a/common/rfb/CSecurityMSLogonII.cxx b/common/rfb/CSecurityMSLogonII.cxx
index d7e23715..e721cdfc 100644
--- a/common/rfb/CSecurityMSLogonII.cxx
+++ b/common/rfb/CSecurityMSLogonII.cxx
@@ -44,8 +44,8 @@
using namespace rfb;
-CSecurityMSLogonII::CSecurityMSLogonII(CConnection* cc)
- : CSecurity(cc)
+CSecurityMSLogonII::CSecurityMSLogonII(CConnection* cc_)
+ : CSecurity(cc_)
{
mpz_init(g);
mpz_init(p);
diff --git a/common/rfb/CSecurityNone.h b/common/rfb/CSecurityNone.h
index 98379c73..df685d0d 100644
--- a/common/rfb/CSecurityNone.h
+++ b/common/rfb/CSecurityNone.h
@@ -29,7 +29,7 @@ namespace rfb {
class CSecurityNone : public CSecurity {
public:
- CSecurityNone(CConnection* cc) : CSecurity(cc) {}
+ CSecurityNone(CConnection* cc_) : CSecurity(cc_) {}
bool processMsg() override { return true; }
int getType() const override {return secTypeNone;}
};
diff --git a/common/rfb/CSecurityPlain.h b/common/rfb/CSecurityPlain.h
index 0cc9e8ed..0dbf4064 100644
--- a/common/rfb/CSecurityPlain.h
+++ b/common/rfb/CSecurityPlain.h
@@ -26,7 +26,7 @@ namespace rfb {
class CSecurityPlain : public CSecurity {
public:
- CSecurityPlain(CConnection* cc) : CSecurity(cc) {}
+ CSecurityPlain(CConnection* cc_) : CSecurity(cc_) {}
bool processMsg() override;
int getType() const override { return secTypePlain; }
};
diff --git a/common/rfb/CSecurityRSAAES.cxx b/common/rfb/CSecurityRSAAES.cxx
index 832574a0..96d96b01 100644
--- a/common/rfb/CSecurityRSAAES.cxx
+++ b/common/rfb/CSecurityRSAAES.cxx
@@ -56,9 +56,9 @@ const int MaxKeyLength = 8192;
using namespace rfb;
-CSecurityRSAAES::CSecurityRSAAES(CConnection* cc, uint32_t _secType,
+CSecurityRSAAES::CSecurityRSAAES(CConnection* cc_, uint32_t _secType,
int _keySize, bool _isAllEncrypted)
- : CSecurity(cc), state(ReadPublicKey),
+ : CSecurity(cc_), state(ReadPublicKey),
keySize(_keySize), isAllEncrypted(_isAllEncrypted), secType(_secType),
clientKey(), clientPublicKey(), serverKey(),
serverKeyN(nullptr), serverKeyE(nullptr),
diff --git a/common/rfb/CSecurityStack.cxx b/common/rfb/CSecurityStack.cxx
index 6b8da8dd..838d68ac 100644
--- a/common/rfb/CSecurityStack.cxx
+++ b/common/rfb/CSecurityStack.cxx
@@ -25,9 +25,9 @@
using namespace rfb;
-CSecurityStack::CSecurityStack(CConnection* cc, int Type,
+CSecurityStack::CSecurityStack(CConnection* cc_, int Type,
CSecurity* s0, CSecurity* s1)
- : CSecurity(cc), type(Type)
+ : CSecurity(cc_), type(Type)
{
state = 0;
state0 = s0;
diff --git a/common/rfb/CSecurityTLS.cxx b/common/rfb/CSecurityTLS.cxx
index 0633dbce..8d8b58fd 100644
--- a/common/rfb/CSecurityTLS.cxx
+++ b/common/rfb/CSecurityTLS.cxx
@@ -82,8 +82,8 @@ static const char* configdirfn(const char* fn)
return full_path;
}
-CSecurityTLS::CSecurityTLS(CConnection* cc, bool _anon)
- : CSecurity(cc), session(nullptr),
+CSecurityTLS::CSecurityTLS(CConnection* cc_, bool _anon)
+ : CSecurity(cc_), session(nullptr),
anon_cred(nullptr), cert_cred(nullptr),
anon(_anon), tlsis(nullptr), tlsos(nullptr),
rawis(nullptr), rawos(nullptr)
diff --git a/common/rfb/CSecurityVeNCrypt.cxx b/common/rfb/CSecurityVeNCrypt.cxx
index 2b74fe29..19dcabc3 100644
--- a/common/rfb/CSecurityVeNCrypt.cxx
+++ b/common/rfb/CSecurityVeNCrypt.cxx
@@ -42,8 +42,9 @@ using namespace std;
static LogWriter vlog("CVeNCrypt");
-CSecurityVeNCrypt::CSecurityVeNCrypt(CConnection* cc, SecurityClient* sec)
- : CSecurity(cc), csecurity(nullptr), security(sec)
+CSecurityVeNCrypt::CSecurityVeNCrypt(CConnection* cc_,
+ SecurityClient* sec)
+ : CSecurity(cc_), csecurity(nullptr), security(sec)
{
haveRecvdMajorVersion = false;
haveRecvdMinorVersion = false;
diff --git a/common/rfb/CSecurityVncAuth.h b/common/rfb/CSecurityVncAuth.h
index 66a6c92d..9a9cf6e0 100644
--- a/common/rfb/CSecurityVncAuth.h
+++ b/common/rfb/CSecurityVncAuth.h
@@ -25,7 +25,7 @@ namespace rfb {
class CSecurityVncAuth : public CSecurity {
public:
- CSecurityVncAuth(CConnection* cc) : CSecurity(cc) {}
+ CSecurityVncAuth(CConnection* cc_) : CSecurity(cc_) {}
virtual ~CSecurityVncAuth() {}
bool processMsg() override;
int getType() const override {return secTypeVncAuth;};
diff --git a/common/rfb/Configuration.cxx b/common/rfb/Configuration.cxx
index a423770d..f58a9c2f 100644
--- a/common/rfb/Configuration.cxx
+++ b/common/rfb/Configuration.cxx
@@ -76,13 +76,13 @@ bool Configuration::set(const char* n, const char* v, bool immutable) {
return set(n, strlen(n), v, immutable);
}
-bool Configuration::set(const char* name, int len,
+bool Configuration::set(const char* paramName, int len,
const char* val, bool immutable)
{
VoidParameter* current = head;
while (current) {
if ((int)strlen(current->getName()) == len &&
- strncasecmp(current->getName(), name, len) == 0)
+ strncasecmp(current->getName(), paramName, len) == 0)
{
bool b = current->setParam(val);
if (b && immutable)
@@ -91,7 +91,7 @@ bool Configuration::set(const char* name, int len,
}
current = current->_next;
}
- return _next ? _next->set(name, len, val, immutable) : false;
+ return _next ? _next->set(paramName, len, val, immutable) : false;
}
bool Configuration::set(const char* config, bool immutable) {
diff --git a/common/rfb/Cursor.cxx b/common/rfb/Cursor.cxx
index f0c72eed..fa596bc5 100644
--- a/common/rfb/Cursor.cxx
+++ b/common/rfb/Cursor.cxx
@@ -33,11 +33,11 @@ using namespace rfb;
static LogWriter vlog("Cursor");
Cursor::Cursor(int width, int height, const Point& hotspot,
- const uint8_t* data) :
+ const uint8_t* data_) :
width_(width), height_(height), hotspot_(hotspot)
{
- this->data = new uint8_t[width_*height_*4];
- memcpy(this->data, data, width_*height_*4);
+ data = new uint8_t[width_*height_*4];
+ memcpy(data, data_, width_*height_*4);
}
Cursor::Cursor(const Cursor& other) :
diff --git a/common/rfb/DecodeManager.cxx b/common/rfb/DecodeManager.cxx
index 63ab987d..ef415886 100644
--- a/common/rfb/DecodeManager.cxx
+++ b/common/rfb/DecodeManager.cxx
@@ -40,8 +40,8 @@ using namespace rfb;
static LogWriter vlog("DecodeManager");
-DecodeManager::DecodeManager(CConnection *conn) :
- conn(conn), threadException(nullptr)
+DecodeManager::DecodeManager(CConnection *conn_) :
+ conn(conn_), threadException(nullptr)
{
size_t cpuCount;
@@ -268,12 +268,9 @@ void DecodeManager::throwThreadException()
throw e;
}
-DecodeManager::DecodeThread::DecodeThread(DecodeManager* manager)
+DecodeManager::DecodeThread::DecodeThread(DecodeManager* manager_)
+ : manager(manager_), stopRequested(false)
{
- this->manager = manager;
-
- stopRequested = false;
-
start();
}
diff --git a/common/rfb/Decoder.cxx b/common/rfb/Decoder.cxx
index a6d9b17c..e9bc9a4f 100644
--- a/common/rfb/Decoder.cxx
+++ b/common/rfb/Decoder.cxx
@@ -37,7 +37,7 @@
using namespace rfb;
-Decoder::Decoder(enum DecoderFlags flags) : flags(flags)
+Decoder::Decoder(enum DecoderFlags flags_) : flags(flags_)
{
}
diff --git a/common/rfb/H264Decoder.cxx b/common/rfb/H264Decoder.cxx
index 26bb9348..53b223db 100644
--- a/common/rfb/H264Decoder.cxx
+++ b/common/rfb/H264Decoder.cxx
@@ -79,9 +79,9 @@ bool H264Decoder::readRect(const Rect& /*r*/,
len = is->readU32();
os->writeU32(len);
- uint32_t flags = is->readU32();
+ uint32_t reset = is->readU32();
- os->writeU32(flags);
+ os->writeU32(reset);
if (!is->hasDataOrRestore(len))
return false;
@@ -100,15 +100,15 @@ void H264Decoder::decodeRect(const Rect& r, const uint8_t* buffer,
{
rdr::MemInStream is(buffer, buflen);
uint32_t len = is.readU32();
- uint32_t flags = is.readU32();
+ uint32_t reset = is.readU32();
H264DecoderContext* ctx = nullptr;
- if (flags & resetAllContexts)
+ if (reset & resetAllContexts)
{
resetContexts();
if (!len)
return;
- flags &= ~(resetContext | resetAllContexts);
+ reset &= ~(resetContext | resetAllContexts);
} else {
ctx = findContext(r);
}
diff --git a/common/rfb/H264WinDecoderContext.cxx b/common/rfb/H264WinDecoderContext.cxx
index e2196520..8422b5c4 100644
--- a/common/rfb/H264WinDecoderContext.cxx
+++ b/common/rfb/H264WinDecoderContext.cxx
@@ -32,6 +32,11 @@ using namespace rfb;
static LogWriter vlog("H264WinDecoderContext");
+// Older MinGW lacks this definition
+#ifndef HAVE_VIDEO_PROCESSOR_MFT
+static GUID CLSID_VideoProcessorMFT = { 0x88753b26, 0x5b24, 0x49bd, { 0xb2, 0xe7, 0xc, 0x44, 0x5c, 0x78, 0xc9, 0x82 } };
+#endif
+
bool H264WinDecoderContext::initCodec() {
os::AutoMutex lock(&mutex);
@@ -47,7 +52,6 @@ bool H264WinDecoderContext::initCodec() {
return false;
}
- GUID CLSID_VideoProcessorMFT = { 0x88753b26, 0x5b24, 0x49bd, { 0xb2, 0xe7, 0xc, 0x44, 0x5c, 0x78, 0xc9, 0x82 } };
if (FAILED(CoCreateInstance(CLSID_VideoProcessorMFT, nullptr, CLSCTX_INPROC_SERVER, IID_IMFTransform, (LPVOID*)&converter)))
{
vlog.error("Cannot create MediaFoundation Video Processor (available only on Windows 8+). Trying ColorConvert DMO.");
@@ -342,8 +346,8 @@ void H264WinDecoderContext::decode(const uint8_t* h264_buffer,
vlog.debug("Frame converted to RGB");
BYTE* out;
- DWORD len;
- converted_buffer->Lock(&out, nullptr, &len);
+ DWORD buflen;
+ converted_buffer->Lock(&out, nullptr, &buflen);
pb->imageRect(rect, out + offset_y * stride + offset_x * 4, (int)stride / 4);
converted_buffer->Unlock();
}
@@ -359,20 +363,20 @@ void H264WinDecoderContext::ParseSPS(const uint8_t* buffer, int length)
if (available == 0) \
{ \
if (length == 0) return; \
- byte = *buffer++; \
+ byte_ = *buffer++; \
length--; \
available = 8; \
} \
- bit = (byte >> --available) & 1; \
+ bit = (byte_ >> --available) & 1; \
} while (0)
#define GET_BITS(n, var) do { \
var = 0; \
- for (int i = n-1; i >= 0; i--) \
+ for (int b = n-1; b >= 0; b--) \
{ \
unsigned bit; \
GET_BIT(bit); \
- var |= bit << i; \
+ var |= bit << b; \
} \
} while (0)
@@ -411,7 +415,7 @@ void H264WinDecoderContext::ParseSPS(const uint8_t* buffer, int length)
length--;
int available = 0;
- uint8_t byte = 0;
+ uint8_t byte_ = 0;
unsigned profile_idc;
unsigned seq_parameter_set_id;
diff --git a/common/rfb/HextileDecoder.cxx b/common/rfb/HextileDecoder.cxx
index 2243d67f..dc9b9be7 100644
--- a/common/rfb/HextileDecoder.cxx
+++ b/common/rfb/HextileDecoder.cxx
@@ -191,10 +191,10 @@ void HextileDecoder::hextileDecode(const Rect& r, rdr::InStream* is,
if (x + w > 16 || y + h > 16) {
throw rfb::Exception("HEXTILE_DECODE: Hextile out of bounds");
}
- T* ptr = buf + y * t.width() + x;
+ ptr = buf + y * t.width() + x;
int rowAdd = t.width() - w;
while (h-- > 0) {
- int len = w;
+ len = w;
while (len-- > 0) *ptr++ = fg;
ptr += rowAdd;
}
diff --git a/common/rfb/HextileEncoder.cxx b/common/rfb/HextileEncoder.cxx
index 729043f0..0666d02d 100644
--- a/common/rfb/HextileEncoder.cxx
+++ b/common/rfb/HextileEncoder.cxx
@@ -38,8 +38,8 @@ BoolParameter improvedHextile("ImprovedHextile",
"ratios by the cost of using more CPU time",
true);
-HextileEncoder::HextileEncoder(SConnection* conn) :
- Encoder(conn, encodingHextile, EncoderPlain)
+HextileEncoder::HextileEncoder(SConnection* conn_) :
+ Encoder(conn_, encodingHextile, EncoderPlain)
{
}
diff --git a/common/rfb/RREEncoder.cxx b/common/rfb/RREEncoder.cxx
index e73a23bf..f3e3b68a 100644
--- a/common/rfb/RREEncoder.cxx
+++ b/common/rfb/RREEncoder.cxx
@@ -31,8 +31,8 @@
using namespace rfb;
-RREEncoder::RREEncoder(SConnection* conn) :
- Encoder(conn, encodingRRE, EncoderPlain)
+RREEncoder::RREEncoder(SConnection* conn_) :
+ Encoder(conn_, encodingRRE, EncoderPlain)
{
}
diff --git a/common/rfb/RawEncoder.cxx b/common/rfb/RawEncoder.cxx
index 2fa1af36..eff8999d 100644
--- a/common/rfb/RawEncoder.cxx
+++ b/common/rfb/RawEncoder.cxx
@@ -29,8 +29,8 @@
using namespace rfb;
-RawEncoder::RawEncoder(SConnection* conn) :
- Encoder(conn, encodingRaw, EncoderPlain)
+RawEncoder::RawEncoder(SConnection* conn_) :
+ Encoder(conn_, encodingRaw, EncoderPlain)
{
}
diff --git a/common/rfb/SConnection.cxx b/common/rfb/SConnection.cxx
index 98fa730b..866d19a2 100644
--- a/common/rfb/SConnection.cxx
+++ b/common/rfb/SConnection.cxx
@@ -46,12 +46,12 @@ using namespace rfb;
static LogWriter vlog("SConnection");
-SConnection::SConnection(AccessRights accessRights)
+SConnection::SConnection(AccessRights accessRights_)
: readyForSetColourMapEntries(false), is(nullptr), os(nullptr),
reader_(nullptr), writer_(nullptr), ssecurity(nullptr),
authFailureTimer(this, &SConnection::handleAuthFailureTimeout),
state_(RFBSTATE_UNINITIALISED), preferredEncoding(encodingRaw),
- accessRights(accessRights), hasRemoteClipboard(false),
+ accessRights(accessRights_), hasRemoteClipboard(false),
hasLocalClipboard(false),
unsolicitedClipboardAttempt(false)
{
@@ -587,7 +587,7 @@ void SConnection::sendClipboardData(const char* data)
// FIXME: This conversion magic should be in SMsgWriter
std::string filtered(convertCRLF(data));
size_t sizes[1] = { filtered.size() + 1 };
- const uint8_t* data[1] = { (const uint8_t*)filtered.c_str() };
+ const uint8_t* datas[1] = { (const uint8_t*)filtered.c_str() };
if (unsolicitedClipboardAttempt) {
unsolicitedClipboardAttempt = false;
@@ -599,7 +599,7 @@ void SConnection::sendClipboardData(const char* data)
}
}
- writer()->writeClipboardProvide(rfb::clipboardUTF8, sizes, data);
+ writer()->writeClipboardProvide(rfb::clipboardUTF8, sizes, datas);
} else {
writer()->writeServerCutText(data);
}
diff --git a/common/rfb/SSecurityNone.h b/common/rfb/SSecurityNone.h
index 944edf8c..a10b4369 100644
--- a/common/rfb/SSecurityNone.h
+++ b/common/rfb/SSecurityNone.h
@@ -28,7 +28,7 @@ namespace rfb {
class SSecurityNone : public SSecurity {
public:
- SSecurityNone(SConnection* sc) : SSecurity(sc) {}
+ SSecurityNone(SConnection* sc_) : SSecurity(sc_) {}
bool processMsg() override { return true; }
int getType() const override {return secTypeNone;}
const char* getUserName() const override {return nullptr;}
diff --git a/common/rfb/SSecurityPlain.cxx b/common/rfb/SSecurityPlain.cxx
index 9bc07cb1..73a21335 100644
--- a/common/rfb/SSecurityPlain.cxx
+++ b/common/rfb/SSecurityPlain.cxx
@@ -68,7 +68,7 @@ bool PasswordValidator::validUser(const char* username)
return false;
}
-SSecurityPlain::SSecurityPlain(SConnection* sc) : SSecurity(sc)
+SSecurityPlain::SSecurityPlain(SConnection* sc_) : SSecurity(sc_)
{
#ifdef WIN32
valid = new WinPasswdValidator();
diff --git a/common/rfb/SSecurityRSAAES.cxx b/common/rfb/SSecurityRSAAES.cxx
index 64a8b523..13e03b22 100644
--- a/common/rfb/SSecurityRSAAES.cxx
+++ b/common/rfb/SSecurityRSAAES.cxx
@@ -70,9 +70,9 @@ BoolParameter SSecurityRSAAES::requireUsername
("RequireUsername", "Require username for the RSA-AES security types",
false, ConfServer);
-SSecurityRSAAES::SSecurityRSAAES(SConnection* sc, uint32_t _secType,
+SSecurityRSAAES::SSecurityRSAAES(SConnection* sc_, uint32_t _secType,
int _keySize, bool _isAllEncrypted)
- : SSecurity(sc), state(SendPublicKey),
+ : SSecurity(sc_), state(SendPublicKey),
keySize(_keySize), isAllEncrypted(_isAllEncrypted), secType(_secType),
serverKey(), clientKey(),
serverKeyN(nullptr), serverKeyE(nullptr),
diff --git a/common/rfb/SSecurityStack.cxx b/common/rfb/SSecurityStack.cxx
index b306cd6a..0ce6d754 100644
--- a/common/rfb/SSecurityStack.cxx
+++ b/common/rfb/SSecurityStack.cxx
@@ -24,9 +24,9 @@
using namespace rfb;
-SSecurityStack::SSecurityStack(SConnection* sc, int Type,
+SSecurityStack::SSecurityStack(SConnection* sc_, int Type,
SSecurity* s0, SSecurity* s1)
- : SSecurity(sc), state(0), state0(s0), state1(s1), type(Type)
+ : SSecurity(sc_), state(0), state0(s0), state1(s1), type(Type)
{
}
diff --git a/common/rfb/SSecurityTLS.cxx b/common/rfb/SSecurityTLS.cxx
index c55f1be8..e2b82f89 100644
--- a/common/rfb/SSecurityTLS.cxx
+++ b/common/rfb/SSecurityTLS.cxx
@@ -66,8 +66,8 @@ StringParameter SSecurityTLS::X509_KeyFile
static LogWriter vlog("TLS");
-SSecurityTLS::SSecurityTLS(SConnection* sc, bool _anon)
- : SSecurity(sc), session(nullptr), anon_cred(nullptr),
+SSecurityTLS::SSecurityTLS(SConnection* sc_, bool _anon)
+ : SSecurity(sc_), session(nullptr), anon_cred(nullptr),
cert_cred(nullptr), anon(_anon), tlsis(nullptr), tlsos(nullptr),
rawis(nullptr), rawos(nullptr)
{
diff --git a/common/rfb/SSecurityVeNCrypt.cxx b/common/rfb/SSecurityVeNCrypt.cxx
index a6dc327e..ce160503 100644
--- a/common/rfb/SSecurityVeNCrypt.cxx
+++ b/common/rfb/SSecurityVeNCrypt.cxx
@@ -38,8 +38,9 @@ using namespace std;
static LogWriter vlog("SVeNCrypt");
-SSecurityVeNCrypt::SSecurityVeNCrypt(SConnection* sc, SecurityServer *sec)
- : SSecurity(sc), security(sec)
+SSecurityVeNCrypt::SSecurityVeNCrypt(SConnection* sc_,
+ SecurityServer *sec)
+ : SSecurity(sc_), security(sec)
{
ssecurity = nullptr;
haveSentVersion = false;
diff --git a/common/rfb/SSecurityVncAuth.cxx b/common/rfb/SSecurityVncAuth.cxx
index 7d5b2664..1276f68a 100644
--- a/common/rfb/SSecurityVncAuth.cxx
+++ b/common/rfb/SSecurityVncAuth.cxx
@@ -52,8 +52,8 @@ VncAuthPasswdParameter SSecurityVncAuth::vncAuthPasswd
("Password", "Obfuscated binary encoding of the password which clients must supply to "
"access the server", &SSecurityVncAuth::vncAuthPasswdFile);
-SSecurityVncAuth::SSecurityVncAuth(SConnection* sc)
- : SSecurity(sc), sentChallenge(false),
+SSecurityVncAuth::SSecurityVncAuth(SConnection* sc_)
+ : SSecurity(sc_), sentChallenge(false),
pg(&vncAuthPasswd), accessRights(AccessNone)
{
}
@@ -116,10 +116,10 @@ bool SSecurityVncAuth::processMsg()
throw AuthFailureException();
}
-VncAuthPasswdParameter::VncAuthPasswdParameter(const char* name,
+VncAuthPasswdParameter::VncAuthPasswdParameter(const char* name_,
const char* desc,
StringParameter* passwdFile_)
-: BinaryParameter(name, desc, nullptr, 0, ConfServer),
+: BinaryParameter(name_, desc, nullptr, 0, ConfServer),
passwdFile(passwdFile_)
{
}
diff --git a/common/rfb/TightEncoder.cxx b/common/rfb/TightEncoder.cxx
index 213f872c..169b74f7 100644
--- a/common/rfb/TightEncoder.cxx
+++ b/common/rfb/TightEncoder.cxx
@@ -60,8 +60,8 @@ static const TightConf conf[10] = {
{ 9, 9, 9 } // 9
};
-TightEncoder::TightEncoder(SConnection* conn) :
- Encoder(conn, encodingTight, EncoderPlain, 256)
+TightEncoder::TightEncoder(SConnection* conn_) :
+ Encoder(conn_, encodingTight, EncoderPlain, 256)
{
setCompressLevel(-1);
}
diff --git a/common/rfb/TightJPEGEncoder.cxx b/common/rfb/TightJPEGEncoder.cxx
index 5c8706ee..de8fd77f 100644
--- a/common/rfb/TightJPEGEncoder.cxx
+++ b/common/rfb/TightJPEGEncoder.cxx
@@ -68,8 +68,8 @@ static const struct TightJPEGConfiguration conf[10] = {
};
-TightJPEGEncoder::TightJPEGEncoder(SConnection* conn) :
- Encoder(conn, encodingTight,
+TightJPEGEncoder::TightJPEGEncoder(SConnection* conn_) :
+ Encoder(conn_, encodingTight,
(EncoderFlags)(EncoderUseNativePF | EncoderLossy), -1, 9),
qualityLevel(-1), fineQuality(-1), fineSubsampling(subsampleUndefined)
{
diff --git a/common/rfb/VNCServerST.cxx b/common/rfb/VNCServerST.cxx
index d18a7983..a8fa1739 100644
--- a/common/rfb/VNCServerST.cxx
+++ b/common/rfb/VNCServerST.cxx
@@ -182,14 +182,14 @@ void VNCServerST::removeSocket(network::Socket* sock) {
handleClipboardAnnounce(*ci, false);
clipboardRequestors.remove(*ci);
- std::string name((*ci)->getPeerEndpoint());
+ std::string peer((*ci)->getPeerEndpoint());
// - Delete the per-Socket resources
delete *ci;
clients.remove(*ci);
- connectionsLog.status("closed: %s", name.c_str());
+ connectionsLog.status("closed: %s", peer.c_str());
// - Check that the desktop object is still required
if (authClientCount() == 0)
diff --git a/common/rfb/ZRLEEncoder.cxx b/common/rfb/ZRLEEncoder.cxx
index c9677337..1e2c6ef4 100644
--- a/common/rfb/ZRLEEncoder.cxx
+++ b/common/rfb/ZRLEEncoder.cxx
@@ -36,8 +36,8 @@ static LogWriter vlog("ZRLEEncoder");
IntParameter zlibLevel("ZlibLevel","[DEPRECATED] Zlib compression level",-1);
-ZRLEEncoder::ZRLEEncoder(SConnection* conn)
- : Encoder(conn, encodingZRLE, EncoderPlain, 127),
+ZRLEEncoder::ZRLEEncoder(SConnection* conn_)
+ : Encoder(conn_, encodingZRLE, EncoderPlain, 127),
zos(nullptr, 2), mos(129*1024)
{
if (zlibLevel != -1) {