QNativeSocketEngine Windows: bring bind() in line with Unix
authorThiago Macieira <thiago.macieira@intel.com>
Thu, 12 Mar 2015 03:13:16 +0000 (20:13 -0700)
committerThiago Macieira <thiago.macieira@intel.com>
Sat, 22 Aug 2015 22:26:43 +0000 (22:26 +0000)
commit2c64e05d497b460f95cd39ea20c4e805b2c8c402
tree78b7535e915f84096036ff2ba9193a5390617362
parentf35b8c004e61dea8ee4ee15a8943ad2b0a0c97d0
QNativeSocketEngine Windows: bring bind() in line with Unix

The IPv4+IPv6 dual stack code that has been in Qt since 5.0 has been
giving test failures for tst_qudpsocket: some binds that shouldn't
succeed do succeed. Instead, copy the core code from the Unix version so
the two OSes will behave the same way.

The one difference in behavior between Windows and Unix is that on Unix
you can bind an IPv4 address to a multicast IP and on Windows you can't.
So I left the "correction" that was in the original code, but I'm unsure
if it is the right thing to do. Are people expecting to join the
multicast group this way?

Change-Id: Iee8cbc07c4434ce9b560ffff13caa1c3d5a7e8fd
Reviewed-by: Richard J. Moore <rich@kde.org>
src/network/socket/qnativesocketengine_win.cpp