]> Some of my projects - anidbudpclient.git/commitdiff
QDate::secsTo() returns qint64 in Qt5, forcing all qBound() args to qint64 should...
authorAPTX <marek321@gmail.com>
Wed, 20 Feb 2013 17:48:54 +0000 (18:48 +0100)
committerAPTX <marek321@gmail.com>
Wed, 20 Feb 2013 17:48:54 +0000 (18:48 +0100)
client.cpp

index 5fd21109e249c9d6802349dadd911e66432a397c..5c04ae23bee0deda43af7835ac6a9b89353f1a4a 100644 (file)
@@ -1082,7 +1082,7 @@ bool Client::possiblyValid(const QByteArray &reply) const
 void Client::resetReplyTimeoutTimer(AbstractReply *cmd)
 {
        Q_ASSERT(cmd);
-       int newTimeout = qBound(0, Client::UDP_API_COMMAND_TIMEOUT - cmd->timeSent().secsTo(QDateTime::currentDateTime()), Client::UDP_API_COMMAND_TIMEOUT);
+       int newTimeout = qBound(qint64(0), qint64(Client::UDP_API_COMMAND_TIMEOUT - cmd->timeSent().secsTo(QDateTime::currentDateTime())), qint64(Client::UDP_API_COMMAND_TIMEOUT));
        newTimeout *= 1000;
        replyTimeoutTimer->start(newTimeout);
 }