summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/irc/dcc/dcc-chat.c5
-rw-r--r--src/irc/dcc/dcc-get.c1
-rw-r--r--src/irc/dcc/dcc-send.c3
3 files changed, 7 insertions, 2 deletions
diff --git a/src/irc/dcc/dcc-chat.c b/src/irc/dcc/dcc-chat.c
index af0084c8..dd9159c3 100644
--- a/src/irc/dcc/dcc-chat.c
+++ b/src/irc/dcc/dcc-chat.c
@@ -320,8 +320,9 @@ static void dcc_chat_listen(CHAT_DCC_REC *dcc)
/* TODO: add paranoia check - see dcc-files.c */
- g_source_remove(dcc->tagconn);
net_disconnect(dcc->handle);
+ g_source_remove(dcc->tagconn);
+ dcc->tagconn = -1;
dcc->starttime = time(NULL);
dcc->handle = handle;
@@ -349,6 +350,8 @@ static void sig_chat_connected(CHAT_DCC_REC *dcc)
/* connect ok. */
g_source_remove(dcc->tagconn);
+ dcc->tagconn = -1;
+
dcc->starttime = time(NULL);
dcc->sendbuf = net_sendbuffer_create(dcc->handle, 0);
dcc->tagread = g_input_add(dcc->handle, G_INPUT_READ,
diff --git a/src/irc/dcc/dcc-get.c b/src/irc/dcc/dcc-get.c
index b04cab40..52c93483 100644
--- a/src/irc/dcc/dcc-get.c
+++ b/src/irc/dcc/dcc-get.c
@@ -180,6 +180,7 @@ static void sig_dccget_connected(GET_DCC_REC *dcc)
}
g_source_remove(dcc->tagconn);
+ dcc->tagconn = -1;
g_free_not_null(dcc->file);
dcc->file = dcc_get_download_path(dcc->arg);
diff --git a/src/irc/dcc/dcc-send.c b/src/irc/dcc/dcc-send.c
index 9d312e13..7c35cc4d 100644
--- a/src/irc/dcc/dcc-send.c
+++ b/src/irc/dcc/dcc-send.c
@@ -128,8 +128,9 @@ static void dcc_send_connected(SEND_DCC_REC *dcc)
that the host of the nick who we sent the request matches the
address who connected us. */
- g_source_remove(dcc->tagconn);
net_disconnect(dcc->handle);
+ g_source_remove(dcc->tagconn);
+ dcc->tagconn = -1;
dcc->starttime = time(NULL);
dcc->handle = handle;