diff options
author | Will Thompson <will.thompson@collabora.co.uk> | 2012-10-30 16:30:10 +0000 |
---|---|---|
committer | Will Thompson <will.thompson@collabora.co.uk> | 2012-10-30 16:30:10 +0000 |
commit | 339c7273dcb604a639ea2b54461b24bd4f252dd6 (patch) | |
tree | 42235f762b78762aa10741f760a429f7a0529f00 /README | |
parent | 67b18831e0ea40dd3f4438426cfb0f703a3fc971 (diff) |
Fix _force_disconnect to actually forcibly disconnect.
Previously, if the network connection had gone away _force_disconnect()
would not actually make the connection die any faster, because
g_io_stream_close_async() waits for a reply by default.
But by pulling the same trick with a cancelled cancellable as is used
for ping timeouts, we can fix this.
I tested this by:
* Connecting to a server (with keepalive-interval=0 to ensure that
doesn't interfere).
* Pulling out my network cable (breaking the connection) but leaving my
wireless connection up.
* calling Disconnect() on the connection.
Before, the connection would never finish disconnecting; after, the
_force_disconnect() timeout actually does something useful and the
connection dies properly.
Diffstat (limited to 'README')
0 files changed, 0 insertions, 0 deletions