From 92b780ff60b4883f2a9beea84de8dd0cb99fd0e6 Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Thu, 18 Apr 2002 15:25:00 +0000 Subject: [PATCH] /SET dcc_send_replace_space_with_underscore - patch by nix@suhs.nu git-svn-id: http://svn.irssi.org/repos/irssi/trunk@2698 dbcabf3a-b0e7-0310-adc4-f8d773084564 --- src/irc/dcc/dcc-send.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/irc/dcc/dcc-send.c b/src/irc/dcc/dcc-send.c index 14b67285..b1f2c950 100644 --- a/src/irc/dcc/dcc-send.c +++ b/src/irc/dcc/dcc-send.c @@ -230,6 +230,11 @@ static void cmd_dcc_send(const char *data, IRC_SERVER_REC *server, fname = g_basename(fname); + /* Replace all the spaces with underscore so that lesser + intellgent clients can communicate.. */ + if (settings_get_bool("dcc_send_replace_space_with_underscore")) + g_strdelimit(fname, " ", '_'); + dcc = dcc_send_create(server, chat, target, fname); dcc->handle = handle; dcc->port = port; @@ -257,7 +262,7 @@ void dcc_send_init(void) { dcc_register_type("SEND"); settings_add_str("dcc", "dcc_upload_path", "~"); - + settings_add_bool("dcc", "dcc_send_replace_space_with_underscore", FALSE); signal_add("dcc destroyed", (SIGNAL_FUNC) sig_dcc_destroyed); command_bind("dcc send", NULL, (SIGNAL_FUNC) cmd_dcc_send); }