From c4f0c4dee6d258992977c445b696dec64b58aa8e Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Sun, 3 Aug 2014 10:03:14 +0100 Subject: [PATCH] Change escaping method for command completion --- src/command_manager.cc | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/command_manager.cc b/src/command_manager.cc index c1d43e2e..96f4cb09 100644 --- a/src/command_manager.cc +++ b/src/command_manager.cc @@ -580,10 +580,7 @@ Completions CommandManager::complete(const Context& context, completions.end += start; for (auto& candidate : completions.candidates) - { - if (candidate.find_first_of(" \t;\"'") != String::npos) - candidate = '"' + escape(candidate, '"', '\\') + '"'; - } + candidate = escape(candidate, " \t;", '\\'); return completions; }