MCPcopy Create free account
hub / github.com/MonaSolutions/MonaServer / handlePidFile

Method handlePidFile

MonaBase/sources/ServerApplication.cpp:324–332  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

322
323
324void ServerApplication::handlePidFile(Exception& ex,const string& value) {
325 ofstream ostr(value.c_str(), ios::out | ios::binary);
326 if (!ostr.good()) {
327 ex.set(Exception::FILE,"Cannot write PID to file ",value);
328 return;
329 }
330 ostr << Process::Id() << endl;
331 _pidFile = value;
332}
333
334#endif
335

Callers

nothing calls this directly

Calls 1

setMethod · 0.45

Tested by

no test coverage detected