typo (I can't spell inactive correctly)

This commit is contained in:
Atlante45 2015-08-26 19:31:33 +02:00
parent 3184dee10a
commit 7a5ed24485
5 changed files with 16 additions and 16 deletions

View file

@ -72,7 +72,7 @@ SendQueue& Connection::getSendQueue() {
QObject::connect(_sendQueue.get(), &SendQueue::packetSent, this, &Connection::packetSent);
QObject::connect(_sendQueue.get(), &SendQueue::packetSent, this, &Connection::recordSentPackets);
QObject::connect(_sendQueue.get(), &SendQueue::packetRetransmitted, this, &Connection::recordRetransmission);
QObject::connect(_sendQueue.get(), &SendQueue::queueInnactive, this, &Connection::queueInnactive);
QObject::connect(_sendQueue.get(), &SendQueue::queueInactive, this, &Connection::queueInactive);
// set defaults on the send queue from our congestion control object
_sendQueue->setPacketSendPeriod(_congestionControl->_packetSendPeriod);
@ -82,8 +82,8 @@ SendQueue& Connection::getSendQueue() {
return *_sendQueue;
}
void Connection::queueInnactive() {
emit connectionInnactive(_destination);
void Connection::queueInactive() {
emit connectionInactive(_destination);
}
void Connection::sendReliablePacket(std::unique_ptr<Packet> packet) {

View file

@ -73,12 +73,12 @@ public:
signals:
void packetSent();
void connectionInnactive(HifiSockAddr sockAdrr);
void connectionInactive(HifiSockAddr sockAdrr);
private slots:
void recordSentPackets(int payload, int total);
void recordRetransmission();
void queueInnactive();
void queueInactive();
private:
void sendACK(bool wasCausedBySyncTimeout = true);

View file

@ -254,12 +254,12 @@ void SendQueue::run() {
}
if (!sentAPacket) {
static const std::chrono::seconds CONSIDER_INNACTIVE_AFTER { 5 };
static const std::chrono::seconds CONSIDER_INACTIVE_AFTER { 5 };
if (flowWindowFull && (clock::now() - _flowWindowFullSince) > CONSIDER_INNACTIVE_AFTER) {
// If the flow window has been full for over CONSIDER_INNACTIVE_AFTER,
// then signal the queue is innactive
emit queueInnactive();
if (flowWindowFull && (clock::now() - _flowWindowFullSince) > CONSIDER_INACTIVE_AFTER) {
// If the flow window has been full for over CONSIDER_INACTIVE_AFTER,
// then signal the queue is inactive
emit queueInactive();
} else {
// During our processing above we didn't send any packets and the flow window is not full.
@ -270,12 +270,12 @@ void SendQueue::run() {
// The packets queue and loss list mutexes are now both locked - check if they're still both empty
if (doubleLock.try_lock() && _packets.empty() && _naks.getLength() == 0) {
// both are empty - let's use a condition_variable_any to wait
auto cvStatus = _emptyCondition.wait_for(doubleLock, CONSIDER_INNACTIVE_AFTER);
auto cvStatus = _emptyCondition.wait_for(doubleLock, CONSIDER_INACTIVE_AFTER);
// Check if we've been innactive for too long
// Check if we've been inactive for too long
if (cvStatus == std::cv_status::timeout) {
emit queueInnactive();
emit queueInactive();
}
// we have the double lock again - it'll be unlocked once it goes out of scope

View file

@ -68,7 +68,7 @@ signals:
void packetSent(int dataSize, int payloadSize);
void packetRetransmitted();
void queueInnactive();
void queueInactive();
private slots:
void run();
@ -105,7 +105,7 @@ private:
std::atomic<int> _flowWindowSize { 0 }; // Flow control window size (number of packets that can be on wire) - set from CC
// Used to detect when the connection becomes innactive for too long
// Used to detect when the connection becomes inactive for too long
bool _flowWindowWasFull = false;
time_point _flowWindowFullSince;

View file

@ -147,7 +147,7 @@ Connection& Socket::findOrCreateConnection(const HifiSockAddr& sockAddr) {
if (it == _connectionsHash.end()) {
auto connection = std::unique_ptr<Connection>(new Connection(this, sockAddr, _ccFactory->create()));
QObject::connect(connection.get(), &Connection::connectionInnactive, this, &Socket::cleanupConnection);
QObject::connect(connection.get(), &Connection::connectionInactive, this, &Socket::cleanupConnection);
it = _connectionsHash.insert(it, std::make_pair(sockAddr, std::move(connection)));
}