mirror of
https://github.com/irssi/irssi.git
synced 2025-01-03 14:56:47 -05:00
Server reconnection tries always the first server in the list where
connection hasn't failed for the last half an hour. If all have failed, just try connecting to any of them. +several code cleanups. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@157 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
6b96becc79
commit
c701648ab3
@ -26,46 +26,50 @@
|
|||||||
extern GList *aliases, *ignores, *completions, *notifies, *hilights, *replaces, *popups;
|
extern GList *aliases, *ignores, *completions, *notifies, *hilights, *replaces, *popups;
|
||||||
|
|
||||||
/* servers */
|
/* servers */
|
||||||
typedef struct
|
typedef struct {
|
||||||
{
|
char *server;
|
||||||
gchar *server;
|
int port;
|
||||||
gchar *ircnet;
|
|
||||||
gchar *password;
|
|
||||||
gint port;
|
|
||||||
gboolean autoconnect;
|
|
||||||
gint cmd_queue_speed; /* override the default if > 0 */
|
|
||||||
time_t last_connect; /* to avoid reconnecting too fast.. */
|
|
||||||
}
|
|
||||||
SETUP_SERVER_REC;
|
|
||||||
|
|
||||||
typedef struct
|
char *ircnet;
|
||||||
{
|
char *password;
|
||||||
gchar *name;
|
int autoconnect;
|
||||||
gchar *nick;
|
int cmd_queue_speed; /* override the default if > 0 */
|
||||||
gchar *username;
|
|
||||||
gchar *realname;
|
char *own_address; /* address to use when connecting this server */
|
||||||
gint max_kicks, max_msgs, max_modes; /* max. number of kicks/msgs/mode changes per command */
|
IPADDR own_ip; /* resolved own_address or full of zeros */
|
||||||
}
|
|
||||||
IRCNET_REC;
|
time_t last_connect; /* to avoid reconnecting too fast.. */
|
||||||
|
int last_failed; /* if last connection attempt failed */
|
||||||
|
} SETUP_SERVER_REC;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
char *name;
|
||||||
|
|
||||||
|
char *nick;
|
||||||
|
char *username;
|
||||||
|
char *realname;
|
||||||
|
|
||||||
|
/* max. number of kicks/msgs/mode changes per command */
|
||||||
|
int max_kicks, max_msgs, max_modes;
|
||||||
|
} IRCNET_REC;
|
||||||
|
|
||||||
extern GList *setupservers; /* list of local servers */
|
extern GList *setupservers; /* list of local servers */
|
||||||
extern GList *ircnets; /* list of available ircnets */
|
extern GList *ircnets; /* list of available ircnets */
|
||||||
|
|
||||||
/* channels */
|
/* channels */
|
||||||
typedef struct
|
typedef struct {
|
||||||
{
|
int autojoin;
|
||||||
gboolean autojoin;
|
|
||||||
gchar *name;
|
|
||||||
gchar *ircnet;
|
|
||||||
gchar *password;
|
|
||||||
|
|
||||||
gchar *botmasks;
|
char *name;
|
||||||
gchar *autosendcmd;
|
char *ircnet;
|
||||||
|
char *password;
|
||||||
|
|
||||||
gchar *background;
|
char *botmasks;
|
||||||
gchar *font;
|
char *autosendcmd;
|
||||||
}
|
|
||||||
SETUP_CHANNEL_REC;
|
char *background;
|
||||||
|
char *font;
|
||||||
|
} SETUP_CHANNEL_REC;
|
||||||
|
|
||||||
extern GList *setupchannels;
|
extern GList *setupchannels;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user