| 61 | } |
| 62 | |
| 63 | std::string escape_shell_arg (const std::string& str) |
| 64 | { |
| 65 | std::string new_str; |
| 66 | new_str.push_back('"'); |
| 67 | for (std::string::const_iterator it(str.begin()); it != str.end(); ++it) { |
| 68 | if (*it == '"' || *it == '\\' || *it == '$' || *it == '`') { |
| 69 | new_str.push_back('\\'); |
| 70 | } |
| 71 | new_str.push_back(*it); |
| 72 | } |
| 73 | new_str.push_back('"'); |
| 74 | return new_str; |
| 75 | } |
| 76 | |
| 77 | uint32_t load_be32 (const unsigned char* p) |
| 78 | { |
no outgoing calls
no test coverage detected