mirror of
https://github.com/lubosz/overte.git
synced 2025-04-16 22:26:42 +02:00
Use direct initialization instead of copy initialization for atomics
This commit is contained in:
parent
f17a1c17f3
commit
93a1cbdcf9
1 changed files with 2 additions and 2 deletions
|
@ -239,7 +239,7 @@ qint64 Socket::writeDatagram(const QByteArray& datagram, const HifiSockAddr& soc
|
|||
int pending = _udpSocket.bytesToWrite();
|
||||
if (bytesWritten < 0 || pending) {
|
||||
int wsaError = 0;
|
||||
static std::atomic<int> previousWsaError = 0;
|
||||
static std::atomic<int> previousWsaError (0);
|
||||
#ifdef WIN32
|
||||
wsaError = WSAGetLastError();
|
||||
#endif
|
||||
|
@ -534,7 +534,7 @@ std::vector<HifiSockAddr> Socket::getConnectionSockAddrs() {
|
|||
|
||||
void Socket::handleSocketError(QAbstractSocket::SocketError socketError) {
|
||||
int wsaError = 0;
|
||||
static std::atomic<int> previousWsaError = 0;
|
||||
static std::atomic<int> previousWsaError(0);
|
||||
#ifdef WIN32
|
||||
wsaError = WSAGetLastError();
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue