From: Gunnar Beutner Date: Fri, 8 Feb 2013 09:30:32 +0000 (+0100) Subject: Bugfix: Fixed incorrect variable name. X-Git-Tag: v0.0.2~506 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ad04a021530fbb094b936c3c762c17152254d7ba;p=icinga2 Bugfix: Fixed incorrect variable name. --- diff --git a/lib/base/application.cpp b/lib/base/application.cpp index e34f2fcb5..aff46e378 100644 --- a/lib/base/application.cpp +++ b/lib/base/application.cpp @@ -460,11 +460,11 @@ void Application::UpdatePidFile(const String& filename) #ifdef F_GETFL int flags; - flags = fcntl(fd, F_GETFL, 0); + flags = fcntl(fileno(m_PidFile), F_GETFL, 0); if (flags < 0) BOOST_THROW_EXCEPTION(PosixException("fcntl failed", errno)); - if (fcntl(fd, F_SETFL, flags | FD_CLOEXEC) < 0) + if (fcntl(fileno(m_PidFile), F_SETFL, flags | FD_CLOEXEC) < 0) BOOST_THROW_EXCEPTION(PosixException("fcntl failed", errno)); #endif /* FD_CLOEXEC */