From d7dbef2fae8eeb3c077faca6eb59e86f636191b8 Mon Sep 17 00:00:00 2001 From: erdgeist <> Date: Sun, 1 Jul 2007 13:38:52 +0000 Subject: Introducing /reconnect command --- vchat-client.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'vchat-client.c') diff --git a/vchat-client.c b/vchat-client.c index dc06015..f521432 100755 --- a/vchat-client.c +++ b/vchat-client.c @@ -40,6 +40,8 @@ unsigned int loggedin = 0; int status = 1; /* we set this, we WANT to quit */ int ownquit = 0; +/* we set this, we DONT want to quit */ +int wantreconnect = 0; /* error string to show after exit */ char errstr[ERRSTRSIZE] = "\0"; @@ -549,8 +551,10 @@ main (int argc, char **argv) /* sanely close connection to server */ vcdisconnect (); - if( !ownquit && getintoption( CF_AUTORECONN ) ) + if( !ownquit && ( getintoption( CF_AUTORECONN ) || wantreconnect ) ) status = 1; + + wantreconnect = 0; } /* call cleanup-hook without signal */ -- cgit v1.2.3