MCPcopy Create free account
hub / github.com/AGWA/git-crypt / exec_command_with_input

Function exec_command_with_input

util.cpp:53–61  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

51}
52
53int exec_command_with_input (const std::vector<std::string>& args, const char* p, size_t len)
54{
55 Coprocess proc;
56 std::ostream* proc_stdin = proc.stdin_pipe();
57 proc.spawn(args);
58 proc_stdin->write(p, len);
59 proc.close_stdin();
60 return proc.wait();
61}
62
63std::string escape_shell_arg (const std::string& str)
64{

Callers 1

gpg_encrypt_to_fileFunction · 0.85

Calls 4

stdin_pipeMethod · 0.45
spawnMethod · 0.45
close_stdinMethod · 0.45
waitMethod · 0.45

Tested by

no test coverage detected