From 56d5c909af6473be64a1ae487b45bd444a9a8553 Mon Sep 17 00:00:00 2001 From: Sergio Ahumada Date: Tue, 4 Sep 2012 19:39:07 +0200 Subject: Use true and false in preference to TRUE and FALSE The TRUE and FALSE macros are obsolete and should be replaced with true and false (all lower case) respectively. Change-Id: Iee352e8173500683e6319be0abbf5bacf29016e0 Reviewed-by: Thiago Macieira --- src/network/socket/qlocalserver_win.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/network') diff --git a/src/network/socket/qlocalserver_win.cpp b/src/network/socket/qlocalserver_win.cpp index 3304c6c6a0..ba879f4eb0 100644 --- a/src/network/socket/qlocalserver_win.cpp +++ b/src/network/socket/qlocalserver_win.cpp @@ -69,7 +69,7 @@ bool QLocalServerPrivate::addListener() SECURITY_ATTRIBUTES sa; sa.nLength = sizeof(SECURITY_ATTRIBUTES); - sa.bInheritHandle = FALSE; //non inheritable handle, same as default + sa.bInheritHandle = false; //non inheritable handle, same as default sa.lpSecurityDescriptor = 0; //default security descriptor QScopedPointer pSD; @@ -166,9 +166,9 @@ bool QLocalServerPrivate::addListener() return false; } } - SetSecurityDescriptorOwner(pSD.data(), pTokenUser->User.Sid, FALSE); - SetSecurityDescriptorGroup(pSD.data(), pTokenGroup->PrimaryGroup, FALSE); - if (!SetSecurityDescriptorDacl(pSD.data(), TRUE, acl, FALSE)) { + SetSecurityDescriptorOwner(pSD.data(), pTokenUser->User.Sid, false); + SetSecurityDescriptorGroup(pSD.data(), pTokenGroup->PrimaryGroup, false); + if (!SetSecurityDescriptorDacl(pSD.data(), false, acl, false)) { setError(QLatin1String("QLocalServerPrivate::addListener")); FreeSid(worldSID); return false; @@ -252,7 +252,7 @@ bool QLocalServerPrivate::listen(const QString &name) // Use only one event for all listeners of one socket. // The idea is that listener events are rare, so polling all listeners once in a while is // cheap compared to waiting for N additional events in each iteration of the main loop. - eventHandle = CreateEvent(NULL, TRUE, FALSE, NULL); + eventHandle = CreateEvent(NULL, true, false, NULL); connectionEventNotifier = new QWinEventNotifier(eventHandle , q); q->connect(connectionEventNotifier, SIGNAL(activated(HANDLE)), q, SLOT(_q_onNewConnection())); @@ -282,7 +282,7 @@ void QLocalServerPrivate::_q_onNewConnection() for (int i = 0; i < listeners.size(); ) { HANDLE handle = listeners[i].handle; if (listeners[i].connected - || GetOverlappedResult(handle, &listeners[i].overlapped, &dummy, FALSE)) + || GetOverlappedResult(handle, &listeners[i].overlapped, &dummy, false)) { listeners.removeAt(i); -- cgit v1.2.3