MCPcopy Create free account
hub / github.com/HexHive/NASS / ExecuteCommand

Function ExecuteCommand

fuzz/libfuzzer/FuzzerUtilPosix.cpp:93–104  ·  view source on GitHub ↗

Return true on success, false otherwise.

Source from the content-addressed store, hash-verified

91
92// Return true on success, false otherwise.
93bool ExecuteCommand(const Command &Cmd, std::string *CmdOutput) {
94 FILE *Pipe = popen(Cmd.toString().c_str(), "r");
95 if (!Pipe)
96 return false;
97
98 if (CmdOutput) {
99 char TmpBuffer[128];
100 while (fgets(TmpBuffer, sizeof(TmpBuffer), Pipe))
101 CmdOutput->append(TmpBuffer);
102 }
103 return pclose(Pipe) == 0;
104}
105
106void SetTimer(int Seconds) {
107 struct itimerval T {

Callers

nothing calls this directly

Calls 2

c_strMethod · 0.45
toStringMethod · 0.45

Tested by

no test coverage detected