Make sure to quote empty strings

This commit is contained in:
Přemysl Eric Janouch 2018-11-02 12:08:43 +01:00
parent 3624636c2f
commit 4ab0db3c04
Signed by: p
GPG Key ID: A0420B94F92B9493
1 changed files with 1 additions and 1 deletions

View File

@ -114,7 +114,7 @@ fun needs_shell_quoting (const string &v) -> bool {
for (auto c : v)
if (strchr ("|&;<>()$`\\\"' \t\n" "*?[#˜=%" "!", c))
return true;
return false;
return v.empty ();
}
fun shell_escape (const string &v) -> string {