diff options
author | Přemysl Janouch <p@janouch.name> | 2018-11-02 12:08:43 +0100 |
---|---|---|
committer | Přemysl Janouch <p@janouch.name> | 2018-11-02 12:08:43 +0100 |
commit | 4ab0db3c0468d0944b87bdf87da5203050db9eb8 (patch) | |
tree | 22c0ce768d8a8edbe07eb204f205fcd43efd9d0e | |
parent | 3624636c2f2b548c40e707475b0e652ab2f47eed (diff) | |
download | sdn-4ab0db3c0468d0944b87bdf87da5203050db9eb8.tar.gz sdn-4ab0db3c0468d0944b87bdf87da5203050db9eb8.tar.xz sdn-4ab0db3c0468d0944b87bdf87da5203050db9eb8.zip |
Make sure to quote empty strings
-rw-r--r-- | sdn.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -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 { |