Commit c67ccad7 authored by Tatsuhiro Tsujikawa's avatar Tatsuhiro Tsujikawa

nghttpx: Use cached get_config()->pid in save_pid()

parent 5d59adc5
...@@ -309,7 +309,7 @@ namespace { ...@@ -309,7 +309,7 @@ namespace {
void save_pid() void save_pid()
{ {
std::ofstream out(get_config()->pid_file.get(), std::ios::binary); std::ofstream out(get_config()->pid_file.get(), std::ios::binary);
out << getpid() << "\n"; out << get_config()->pid << "\n";
out.close(); out.close();
if(!out) { if(!out) {
LOG(ERROR) << "Could not save PID to file " LOG(ERROR) << "Could not save PID to file "
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment