2000-04-26 04:03:38 -04:00
|
|
|
#ifndef __SERVER_RECONNECT_H
|
|
|
|
#define __SERVER_RECONNECT_H
|
|
|
|
|
2000-06-01 20:36:54 -04:00
|
|
|
/* wait for half an hour before trying to reconnect to host where last
|
|
|
|
connection failed */
|
|
|
|
#define FAILED_RECONNECT_WAIT (60*30)
|
|
|
|
|
2000-04-26 04:03:38 -04:00
|
|
|
typedef struct {
|
2001-06-08 17:19:08 -04:00
|
|
|
int tag;
|
2000-04-26 04:03:38 -04:00
|
|
|
time_t next_connect;
|
|
|
|
|
2000-08-26 11:39:44 -04:00
|
|
|
SERVER_CONNECT_REC *conn;
|
2000-04-26 04:03:38 -04:00
|
|
|
} RECONNECT_REC;
|
|
|
|
|
|
|
|
extern GSList *reconnects;
|
|
|
|
|
2001-02-18 21:15:15 -05:00
|
|
|
void reconnect_save_status(SERVER_CONNECT_REC *conn, SERVER_REC *server);
|
2000-11-25 21:09:15 -05:00
|
|
|
void server_reconnect_destroy(RECONNECT_REC *rec, int free_conn);
|
|
|
|
|
2000-04-26 04:03:38 -04:00
|
|
|
void servers_reconnect_init(void);
|
|
|
|
void servers_reconnect_deinit(void);
|
|
|
|
|
|
|
|
#endif
|