ratox

FIFO based tox client
git clone git://git.2f30.org/ratox
Log | Files | Refs | README | LICENSE

commit e1aa1132ef821c2068b7ec7cc20936b63611e051
parent 926b69de44057351e1af1316a4093ba0ff619412
Author: sin <sin@2f30.org>
Date:   Fri, 26 Sep 2014 16:54:25 +0100

Just flag the signal, nothing more

Diffstat:
Mratox.c | 5+++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/ratox.c b/ratox.c @@ -165,7 +165,7 @@ static Tox_Options toxopt; static uint8_t *passphrase; static uint32_t pplen; static uint8_t toilet[BUFSIZ]; -static int running = 1; +static sig_atomic_t running = 1; static int ipv6; static int tcpflag; static int proxyflag; @@ -1296,7 +1296,6 @@ loop(void) static void initshutdown(int sig) { - printout("Shutting down...\n"); running = 0; } @@ -1307,6 +1306,8 @@ shutdown(void) struct friend *f, *ftmp; struct request *r, *rtmp; + printout("Shutting down...\n"); + /* Friends */ for (f = TAILQ_FIRST(&friendhead); f; f = ftmp) { ftmp = TAILQ_NEXT(f, entry);