aboutsummaryrefslogtreecommitdiffstats
path: root/src/ClientExpire.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-01-14 23:42:06 +0100
committerMax Kellermann <max@duempel.org>2013-01-15 12:15:33 +0100
commit39439b80f5d1574e67f337a047869cf067c396b7 (patch)
tree5e28e61d4895da86189d14cde9f1e238c18079a8 /src/ClientExpire.cxx
parent396480cf94fbeda581acb6a78c42c7ec610d04a4 (diff)
downloadmpd-39439b80f5d1574e67f337a047869cf067c396b7.tar.gz
mpd-39439b80f5d1574e67f337a047869cf067c396b7.tar.xz
mpd-39439b80f5d1574e67f337a047869cf067c396b7.zip
Client: rebase on the new BufferedSocket class
Diffstat (limited to '')
-rw-r--r--src/ClientExpire.cxx15
1 files changed, 4 insertions, 11 deletions
diff --git a/src/ClientExpire.cxx b/src/ClientExpire.cxx
index f599e472d..56b003df8 100644
--- a/src/ClientExpire.cxx
+++ b/src/ClientExpire.cxx
@@ -26,18 +26,11 @@ static guint expire_source_id;
void
Client::SetExpired()
{
- if (!IsExpired())
- client_schedule_expire();
+ if (IsExpired())
+ return;
- if (source_id != 0) {
- g_source_remove(source_id);
- source_id = 0;
- }
-
- if (channel != NULL) {
- g_io_channel_unref(channel);
- channel = nullptr;
- }
+ client_schedule_expire();
+ BufferedSocket::Close();
}
static void