removed obsolete contrib/daemonchk.c

this also closes CVE-2013-7205 because we do not longer ship the old cgis and
this file was hopefully the last part of it.

Signed-off-by: Sven Nierlein <sven@consol.de>
Replace the COPYING file

Nagios, a GPLv2 (or later?) project, had its license in a LICENSE file.
The autotoolsification auto-inserted a GPLv3 license into the GNU
standard COPYING file, which means depending on what you're used to, the
license seems to vary.

Drop the LICENSE file and use the expected text in the COPYING file
instead.

Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
commands: Inspect correct option for passive host check acceptance

This patch fixes a bug where having passive service checks disabled
would not only disable passive service checks, but also implicitly
disable passive host checks.

You might think this would also have the effect of _not_ disabling
passive host checks (since we check the wrong option), but fortunately
we don't trust the command processing code and check the correct option
once we actually process the host check.

Signed-off-by: Anton Lofgren <alofgren@op5.com>
Merge pull request #16 from catharsis/master

commands: Inspect correct option for passive host check acceptance
commands: Let positive values of sticky mean yes

The acknowledge commands takes a "sticky" parameter. Before this patch,
0, 1, and >3 meant "not sticky", while 2 meant "sticky". I know why this
happened - internally, nagios uses 0 for "not acknowledged" and 1 for
"acknowledged", so internally, 2 is the first number available to use as
"stickily acknowledged". But. Really?

This changes the host and service acknowledge commands so that <=0 means
no and >0 means yes, the way all other booleans work. This does break
userspace API - though I suspect anyone using positive values other than
2 still intend for them to mean true, and are scratching their heads as
to why they don't work, as in op5#7794 or op5#5438.

Change-Id: Ib440df797b63c18d440cc1802bcce03b32341968
Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
naemon/naemon.c: removed uneeded else statement

to make code cleaner, removed an uneeded `else'
statement on naemon's main flow

Signed-off-by: Ricardo Maraschini <ricardo.maraschini@gmail.com>
naemon/sretention.c: removing uneeded comparsion

xrddefault_read_state_information() always returns OK or ERROR

Signed-off-by: Ricardo Maraschini <ricardo.maraschini@gmail.com>
Merge pull request #18 from ricardomaraschini/ricardo-patches

naemon/naemon.c: removed uneeded else statement
naemon/workers.c: removed uneeded variable attribution

`i' is set to zero a few lines below

Signed-off-by: Ricardo Maraschini <ricardo.maraschini@gmail.com>
fixed pkill on debian wheezy (fixes #17) (snarf)

Signed-off-by: Sven Nierlein <sven@consol.de>
Merge pull request #19 from ricardomaraschini/patches

naemon/workers.c: removed uneeded variable attribution
removed obsolete changelog file

No need to maintain 2 changelogs and ChangeLog is the one autotools
wants.

Signed-off-by: Sven Nierlein <sven@nierlein.de>
logging: Fixed changing ownership on debug file

Patch based on nagios ba2c19d, by Eric Stanley <estanley@nagios.com>

Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
xodtemplate: Inherit hourly value from template

Patch based on nagios c49bd4b, by Scott Wilkerson
<swilkerson@nagios.com>.

Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
downtime: Notify when flexible downtimes expire

Patch based on nagios 210fbbb, by Dan Wittenberg.

Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
worker: Change dir to something that exists

Try to change working directory to $HOME. If that fails, go for "/". If
that fails, too, I don't know what do do and just do nothing - when
someone can describe when that could reasonably happen, they get to
dictate what is the proper course of action.

Signed-off-by: Robin Sonefors <robin.sonefors@op5.com>
check_file_size(): Fixed wrong file name on logging

we've tried to open `path' file and in case of fail, we log that
we failed to open `log_file' instead of `path'

Signed-off-by: Ricardo Maraschini <ricardo.maraschini@gmail.com>
naemon/checks.c: returning OK earlier when checking service

if run_async_service_check() returns OK, we should return
immediately, making code easier to read and avoiding
identation madness

Signed-off-by: Ricardo Maraschini <ricardo.maraschini@gmail.com>
checks.c: cleaned `reschedule failed scheduled service checks'

if a given scheduled service check failed by any reason we
need to reschedule it only if it is supposed to be scheduled.

the old code works like a charm, despite the fact it looks
a little bit bizarre. imho new code gets much more cleaner this way,
no functional changes.

Signed-off-by: Ricardo Maraschini <ricardo.maraschini@gmail.com>
removed spec from update-version script

this spec file does not exist anymore

Signed-off-by: Sven Nierlein <sven@consol.de>