GSocket: fix g_socket_bind() allow_reuse semantics
authorDan Winship <danw@gnome.org>
Sun, 17 Feb 2013 20:11:18 +0000 (15:11 -0500)
committerDan Winship <danw@gnome.org>
Sat, 17 Aug 2013 17:26:42 +0000 (13:26 -0400)
commit547df5937cc3b821498e27eb55cebc1f414ce597
tree74b821d2777a6ff229ce3b2626c8755b9aec6391
parent2ea4af6f019632b810ea6f7c0f0c44498cf5dddf
GSocket: fix g_socket_bind() allow_reuse semantics

With UDP sockets, g_socket_bind() with allow_reuse=TRUE on Linux
behaved in a way that the documentation didn't suggest, and that
didn't match other OSes. (Specifically, it allowed binding multiple
multicast sockets to the same address.)

Since this behavior is useful, and since allow_reuse didn't have any
other meaning with UDP sockets, update the docs to reflect the Linux
behavior, and make it do the same thing on non-Linux.

https://bugzilla.gnome.org/show_bug.cgi?id=689245
gio/gsocket.c
gio/tests/socket.c