From 924e1219548253a1eaf744c1ea61a8466ec98d63 Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Thu, 7 Jul 2005 17:59:23 -0700 Subject: [PATCH] Mark more characters shell-safe. I still worry about just quoting things when passing it off to "ssh" or "sh -c", so I'm being anal. But _, ^ and , are certainly ok and while both ~ and @ can have speacial meaning to shell/ssh they are benign. --- connect.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/connect.c b/connect.c index 075683e8..3d4b31d3 100644 --- a/connect.c +++ b/connect.c @@ -57,7 +57,9 @@ static char *shell_safe(char *url) ['A'...'Z'] = 1, ['.'] = 1, ['/'] = 1, ['-'] = 1, ['+'] = 1, - [':'] = 1 + [':'] = 1, ['_'] = 1, + ['@'] = 1, [','] = 1, + ['~'] = 1, ['^'] = 1, }; while ((c = *n++) != 0) { -- 2.11.0