diff --git a/clients/upsmon.c b/clients/upsmon.c index 1bf6939515..b31444d047 100644 --- a/clients/upsmon.c +++ b/clients/upsmon.c @@ -1300,7 +1300,7 @@ static void loadconfig(void) /* SIGPIPE handler */ static void sigpipe(int sig) { - upsdebugx(1, "SIGPIPE: dazed and confused, but continuing..."); + upsdebugx(1, "SIGPIPE: dazed and confused, but continuing after signal %i...", sig); } /* SIGQUIT, SIGTERM handler */ diff --git a/clients/upssched.c b/clients/upssched.c index 09890561ca..8db129ea2e 100644 --- a/clients/upssched.c +++ b/clients/upssched.c @@ -908,9 +908,15 @@ static void checkconf(void) int main(int argc, char **argv) { - const char *prog = xbasename(argv[0]); + const char *prog = NULL; + /* More a use for argc to avoid warnings than a real need: */ + if (argc > 0) { + xbasename(argv[0]); + } else { + xbasename("upssched"); + } - verbose = 1; /* TODO: remove when done testing */ + verbose = 1; /* TODO: remove when done testing, or add -D */ /* normally we don't have stderr, so get this going to syslog early */ open_syslog(prog); diff --git a/clients/upsset.c b/clients/upsset.c index 57ddc2daab..cf7c6a05f6 100644 --- a/clients/upsset.c +++ b/clients/upsset.c @@ -746,6 +746,8 @@ static void print_rw(const char *upsname, const char *varname) { const char *tmp; + printf("\n", upsname); + printf("