summaryrefslogtreecommitdiff
path: root/src/irc/dcc/dcc.c
diff options
context:
space:
mode:
authorLemonBoy <thatlemon@gmail.com>2016-03-21 15:23:12 +0100
committerLemonBoy <thatlemon@gmail.com>2016-03-22 16:00:00 +0100
commit8b54366d9525d94ae4b1d0d6914b22b7bf73112e (patch)
tree5e7521080758dc73a0071d10743f7b27141e8906 /src/irc/dcc/dcc.c
parent83bee9c6b73d01b749e3c8a56e0683569e6a1ae2 (diff)
downloadirssi-8b54366d9525d94ae4b1d0d6914b22b7bf73112e.zip
Support quoted filenames in some /DCC commands
Diffstat (limited to 'src/irc/dcc/dcc.c')
-rw-r--r--src/irc/dcc/dcc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/irc/dcc/dcc.c b/src/irc/dcc/dcc.c
index 17f6c477..c51f7c7a 100644
--- a/src/irc/dcc/dcc.c
+++ b/src/irc/dcc/dcc.c
@@ -490,7 +490,7 @@ static void event_no_such_nick(IRC_SERVER_REC *server, char *data)
static void cmd_dcc_close(char *data, IRC_SERVER_REC *server)
{
GSList *tmp, *next;
- char *typestr, *nick, *arg;
+ char *typestr, *nick, *arg, *fname;
void *free_arg;
int found, type;
@@ -510,13 +510,15 @@ static void cmd_dcc_close(char *data, IRC_SERVER_REC *server)
return;
}
+ fname = cmd_get_quoted_param(&arg);
+
found = FALSE;
for (tmp = dcc_conns; tmp != NULL; tmp = next) {
DCC_REC *dcc = tmp->data;
next = tmp->next;
if (dcc->type == type && g_ascii_strcasecmp(dcc->nick, nick) == 0 &&
- (*arg == '\0' || g_strcmp0(dcc->arg, arg) == 0)) {
+ (*fname == '\0' || g_strcmp0(dcc->arg, fname) == 0)) {
dcc_reject(dcc, server);
found = TRUE;
}