qt5base-lts/tests/auto/corelib/kernel/qsocketnotifier
Alex Trotsenko 124b9a6ff8 Improve suppression of spurious socket notifications under Windows
There were still two cases where spurious notifications would be
possible:

    - user calls hasPendingDatagrams()/pendingDatagramSize() on UDP
      socket somewhere outside the slot connected to readyRead()
      signal (::WSARecvFrom posts FD_READ notification, even if
      a notification for incoming datagram already exists in the
      message queue);
    - a socket was registered to receive several types of event and
      WM_QT_ACTIVATENOTIFIERS message is located between the
      different events for this socket in the queue.

Provided patch ensures that the message queue is synchronized with
the Qt event processing mechanism and adds a way to detect spurious
notifications inside the window procedure.

Task-number: QTBUG-58214
Change-Id: I49609dace601f300de09875ff1653617efabd72f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Peter Seiderer <ps.report@gmx.net>
2017-05-03 06:46:18 +00:00
..
.gitignore Moving relevant tests to corelib/kernel 2011-09-01 12:42:14 +02:00
BLACKLIST Blacklist and skip various tests that are flakey 2015-06-14 10:50:45 +00:00
qsocketnotifier.pro Use qtConfig throughout in qtbase 2016-08-19 04:28:05 +00:00
tst_qsocketnotifier.cpp Improve suppression of spurious socket notifications under Windows 2017-05-03 06:46:18 +00:00