"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/monit.c" between
monit-5.25.3.tar.gz and monit-5.26.0.tar.gz

About: Monit is a utility for managing and monitoring processes, files, directories and filesystems (with automatic error recovery).

monit.c  (monit-5.25.3):monit.c  (monit-5.26.0)
skipping to change at line 526 skipping to change at line 526
Run.flags &= ~Run_Once; Run.flags &= ~Run_Once;
if (can_http()) { if (can_http()) {
if (Run.httpd.flags & Httpd_Net) if (Run.httpd.flags & Httpd_Net)
LogInfo("Starting Monit %s daemon with http inte rface at [%s]:%d\n", VERSION, Run.httpd.socket.net.address ? Run.httpd.socket.ne t.address : "*", Run.httpd.socket.net.port); LogInfo("Starting Monit %s daemon with http inte rface at [%s]:%d\n", VERSION, Run.httpd.socket.net.address ? Run.httpd.socket.ne t.address : "*", Run.httpd.socket.net.port);
else if (Run.httpd.flags & Httpd_Unix) else if (Run.httpd.flags & Httpd_Unix)
LogInfo("Starting Monit %s daemon with http inte rface at %s\n", VERSION, Run.httpd.socket.unix.path); LogInfo("Starting Monit %s daemon with http inte rface at %s\n", VERSION, Run.httpd.socket.unix.path);
} else { } else {
LogInfo("Starting Monit %s daemon\n", VERSION); LogInfo("Starting Monit %s daemon\n", VERSION);
} }
if (Run.startdelay)
LogInfo("Monit start delay set to %ds\n", Run.startdelay
);
if (! (Run.flags & Run_Foreground)) if (! (Run.flags & Run_Foreground))
daemonize(); daemonize();
if (! file_createPidFile(Run.files.pid)) { if (! file_createPidFile(Run.files.pid)) {
LogError("Monit daemon died\n"); LogError("Monit daemon died\n");
exit(1); exit(1);
} }
if (! State_open()) if (! State_open())
exit(1); exit(1);
State_restore(); State_restore();
atexit(file_finalize); atexit(file_finalize);
if (Run.startdelay) { if (Run.startdelay && State_reboot()) {
time_t now = Time_now(); time_t now = Time_now();
time_t delay = now + Run.startdelay; time_t delay = now + Run.startdelay;
LogInfo("Monit will delay for %ds on first start after r
eboot ...\n", Run.startdelay);
/* sleep can be interrupted by signal => make sure we pa used long enough */ /* sleep can be interrupted by signal => make sure we pa used long enough */
while (now < delay) { while (now < delay) {
sleep((unsigned int)(delay - now)); sleep((unsigned int)(delay - now));
if (Run.flags & Run_Stopped) if (Run.flags & Run_Stopped)
do_exit(false); do_exit(false);
now = Time_now(); now = Time_now();
} }
} }
if (can_http()) if (can_http())
 End of changes. 3 change blocks. 
5 lines changed or deleted 4 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)