search for: exit_flag

Displaying 9 results from an estimated 9 matches for "exit_flag".

2011 Feb 15
2
[Bug 535583] Excessive logging by apcsmart program
2011/2/15 Lupe Christoph > On Monday, 2011-02-14 at 21:54:20 -0000, Arnaud Quette wrote: > > I definitely need more info! > > please reply to ALL: > > > - what is the exact model and date of manufacturing? > > SmartUPS 300I NET. I have the serial number (GS9809283199) but no date. > it seems to be a recent model. > - are you sure this unit is ok? > >
2011 Feb 15
2
[Bug 535583] Excessive logging by apcsmart program
2011/2/15 Lupe Christoph > On Monday, 2011-02-14 at 21:54:20 -0000, Arnaud Quette wrote: > > I definitely need more info! > > please reply to ALL: > > > - what is the exact model and date of manufacturing? > > SmartUPS 300I NET. I have the serial number (GS9809283199) but no date. > it seems to be a recent model. > - are you sure this unit is ok? > >
2007 Jun 21
2
[nut-commits] svn commit r971 - in trunk: . drivers
...^^^^^^^^^^^^^^^^^^ If the communication to the UPS is lost (and can't be established again), it will stay in this loop forever and therefor never leave the upsdrv_updateinfo() function. This is bad for two reasons: #1 The driver won't respond to a termination signal anymore, since the exit_flag (that is set by a SIGTERM for instance) is not evaluated in upsdrv_updateinfo(). #2 The driver won't respond to the server either, so it will appear (and be flagged) dead, while the actual problem is in the connection to the UPS. People might try to restart it, which isn't going to work du...
2007 Nov 20
2
Mustek Powermust 600VA
Hi, I'm having a hard time configuring a Mustek Powermust 600VA ups to work via USB with nut. I read somewhere that nut works OK via the rs232 cable, but unfortunately I don't have a COM port in my computer. The kernel detects the ups as an Xbox pad :) and loads the xpad module. I tried running /lib/nut/megatec with different /dev/ttySx but it displays megatec protocol UPS was not
2014 Dec 09
3
Tiny suggestion for upslog.c
...onds). I think that the patch is still valid against the latest source in GIT but was originally coded against 2.2.x. thanks Andy --- nut-2.6.5/clients/upslog.c 2014-12-08 23:23:33.274059582 +0000 +++ nut-2.6.5/clients/upslog.c 2014-12-08 23:24:02.906586228 +0000 @@ -76,6 +76,11 @@ exit_flag = sig; } +static void set_print_now_flag(int sig) +{ + /* no need to do anything, the signal will cause sleep to be interrupted */ +} + /* handlers: reload on HUP, exit on INT/QUIT/TERM */ static void setup_signals(void) { @@ -96,6 +101,11 @@ fatal_with_errno(EXIT_FAILURE, &q...
2016 Jul 11
0
Proposal for technique to stop a timer at any moment
..., "UPSDESC")) { get_upsdesc(client, arg[1]); diff -rup nut-2.7.4.orig/server/upsd.c nut-2.7.4.dev/server/upsd.c --- nut-2.7.4.orig/server/upsd.c 2015-12-29 13:08:34.000000000 +0100 +++ nut-2.7.4.dev/server/upsd.c 2016-07-01 09:56:59.589903339 +0200 @@ -848,6 +848,32 @@ static void set_exit_flag(int sig) exit_flag = sig; } +static void sigusr1_handler(int sig) +{ + /* SIGUSR1 signals are passed on to every known UPS RP */ + upstype_t *u; + + for (u = firstups; u; u = u->next) { + if ( u->sigusr1 < MAX_SIGUSR1 ) { + (u->sigusr1)++; + upsdebugx(1, "%s: UPS %s, si...
2007 Jan 06
1
Re: [nut-commits] svn commit r710 - in trunk: . clients server
...naddr; > +#else > static char *listenaddr = NULL; > > /* AF_ */ > > static int opt_af = AF_UNSPEC; > +#endif > > /* signal handlers */ > static struct sigaction sa; > @@ -77,6 +81,7 @@ > /* set by signal handlers */ > static int reload_flag = 0, exit_flag = 0; > > +#ifdef HAVE_IPV6 > const char *inet_ntopW (struct sockaddr_storage *s) { > static char str[40]; > > @@ -90,6 +95,7 @@ > return NULL; > } > } > +#endif > > /* return a pointer to the named ups if possible */ > upstype *get_ups_ptr(con...
2007 Jan 06
3
Re: [nut-commits] svn commit r708 - in trunk: . clients server
...tic struct in_addr listenaddr; > +static char *listenaddr = NULL; > + > +/* AF_ */ > + > +static int opt_af = AF_UNSPEC; > > /* signal handlers */ > static struct sigaction sa; > @@ -72,6 +77,20 @@ > /* set by signal handlers */ > static int reload_flag = 0, exit_flag = 0; > > +const char *inet_ntopW (struct sockaddr_storage *s) { > + static char str[40]; > + > + switch (s->ss_family) { > + case AF_INET: > + return inet_ntop (AF_INET, &(((struct sockaddr_in *)s)->sin_addr), str, 16); > + case AF_INET6: > + return inet_nto...
2011 Feb 07
4
[PATCH/RFC v2 0/3] Updates to ACP smart driver
This is 2nd version of the earlier patch featuring a few new features and fixes to the apcsmart driver, following the remarks in: http://www.mail-archive.com/nut-upsdev at lists.alioth.debian.org/msg02294.html Major changes from v1: - handle battery.charge and battery.runtime checks at main.c level - handle "immutable but writable" conflict gracefully at driver level -