MCPcopy Create free account
hub / github.com/Kitware/CMake / CallSwVers

Method CallSwVers

Source/kwsys/SystemInformation.cxx:5503–5519  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5501}
5502
5503int SystemInformationImplementation::CallSwVers(char const* arg,
5504 std::string& ver)
5505{
5506#ifdef __APPLE__
5507 std::vector<char const*> args;
5508 args.push_back("sw_vers");
5509 args.push_back(arg);
5510 args.push_back(nullptr);
5511 ver = this->RunProcess(args);
5512 this->TrimNewline(ver);
5513#else
5514 // avoid C4100
5515 (void)arg;
5516 (void)ver;
5517#endif
5518 return 0;
5519}
5520
5521void SystemInformationImplementation::TrimNewline(std::string& output)
5522{

Callers 1

QueryOSInformationMethod · 0.95

Calls 3

RunProcessMethod · 0.95
TrimNewlineMethod · 0.95
push_backMethod · 0.80

Tested by

no test coverage detected