From fb9f6185db724c0fc3f30ec46ad70353e3a848de Mon Sep 17 00:00:00 2001 From: Brad Hefta-Gaub Date: Tue, 24 May 2016 17:19:53 -0700 Subject: [PATCH] CR feedback --- domain-server/src/DomainGatekeeper.cpp | 5 +++-- interface/src/Application.cpp | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/domain-server/src/DomainGatekeeper.cpp b/domain-server/src/DomainGatekeeper.cpp index 9023510214..b940d46849 100644 --- a/domain-server/src/DomainGatekeeper.cpp +++ b/domain-server/src/DomainGatekeeper.cpp @@ -535,9 +535,10 @@ void DomainGatekeeper::sendConnectionDeniedPacket(const QString& reason, const H // this is an agent and we've decided we won't let them connect - send them a packet to deny connection QByteArray utfString = reason.toUtf8(); quint16 payloadSize = utfString.size(); - + // setup the DomainConnectionDenied packet - auto connectionDeniedPacket = NLPacket::create(PacketType::DomainConnectionDenied); + auto connectionDeniedPacket = NLPacket::create(PacketType::DomainConnectionDenied, + payloadSize + sizeof(payloadSize) + sizeof(uint8_t)); // pack in the reason the connection was denied (the client displays this) if (payloadSize > 0) { diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index f3322caffb..48b418b93c 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -4594,7 +4594,7 @@ void Application::setSessionUUID(const QUuid& sessionUUID) const { // If we're not getting anything back from the domain server checkin, it might be that the domain speaks an -// older version of the DomainConnectRequest protocal. We will attempt to send and older version of DomainConnectRequest. +// older version of the DomainConnectRequest protocol. We will attempt to send and older version of DomainConnectRequest. // We won't actually complete the connection, but if the server responds, we know that it needs to be upgraded (or we // need to be downgraded to talk to it). void Application::limitOfSilentDomainCheckInsReached() {