From 79c6f9f8fff2b4c4627353e8a8eeb591d99a2098 Mon Sep 17 00:00:00 2001 From: Wilmer van der Gaast Date: Tue, 25 Apr 2006 09:21:49 +0200 Subject: Implemented better quoting for root command arguments. (Support for backslashes instead of just "' quotes.) --- root_commands.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'root_commands.c') diff --git a/root_commands.c b/root_commands.c index 0b5f4da5..6d9868ac 100644 --- a/root_commands.c +++ b/root_commands.c @@ -57,6 +57,13 @@ void root_command_string( irc_t *irc, user_t *u, char *command, int flags ) s --; } } + else if( *s == '\\' && ( ( !q && s[1] ) || ( q && q == s[1] ) ) ) + { + char *cpy; + + for( cpy = s; *cpy; cpy ++ ) + cpy[0] = cpy[1]; + } else if( *s == q ) { q = *s = 0; -- cgit v1.2.3