mirror of
https://github.com/irssi/irssi.git
synced 2024-12-04 14:46:39 -05:00
Added no_connect to SERVER_CONNECT_REC, also exported a few other variables
to perl. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@3042 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
45f86f7b5f
commit
27f54e286f
@ -30,5 +30,6 @@ unsigned int reconnection:1; /* we're trying to reconnect */
|
||||
unsigned int no_autojoin_channels:1; /* don't autojoin any channels */
|
||||
unsigned int unix_socket:1; /* Connect using named unix socket */
|
||||
unsigned int use_ssl:1; /* this connection uses SSL */
|
||||
unsigned int no_connect:1; /* don't connect() at all, it's done by plugin */
|
||||
char *channels;
|
||||
char *away_reason;
|
||||
|
@ -178,6 +178,9 @@ static void server_real_connect(SERVER_REC *server, IPADDR *ip,
|
||||
|
||||
signal_emit("server connecting", 2, server, ip);
|
||||
|
||||
if (server->connrec->no_connect)
|
||||
return;
|
||||
|
||||
if (ip != NULL) {
|
||||
own_ip = ip == NULL ? NULL :
|
||||
(IPADDR_IS_V6(ip) ? server->connrec->own_ip6 :
|
||||
|
@ -265,6 +265,7 @@ void perl_connect_fill_hash(HV *hv, SERVER_CONNECT_REC *conn)
|
||||
hv_store(hv, "type", 4, new_pv(type), 0);
|
||||
hv_store(hv, "chat_type", 9, new_pv(chat_type), 0);
|
||||
|
||||
hv_store(hv, "tag", 3, new_pv(conn->tag), 0);
|
||||
hv_store(hv, "address", 7, new_pv(conn->address), 0);
|
||||
hv_store(hv, "port", 4, newSViv(conn->port), 0);
|
||||
hv_store(hv, "chatnet", 7, new_pv(conn->chatnet), 0);
|
||||
@ -273,6 +274,12 @@ void perl_connect_fill_hash(HV *hv, SERVER_CONNECT_REC *conn)
|
||||
hv_store(hv, "wanted_nick", 11, new_pv(conn->nick), 0);
|
||||
hv_store(hv, "username", 8, new_pv(conn->username), 0);
|
||||
hv_store(hv, "realname", 8, new_pv(conn->realname), 0);
|
||||
|
||||
hv_store(hv, "reconnection", 12, newSViv(conn->reconnection), 0);
|
||||
hv_store(hv, "no_autojoin_channels", 20, newSViv(conn->no_autojoin_channels), 0);
|
||||
hv_store(hv, "unix_socket", 11, newSViv(conn->unix_socket), 0);
|
||||
hv_store(hv, "use_ssl", 7, newSViv(conn->use_ssl), 0);
|
||||
hv_store(hv, "no_connect", 10, newSViv(conn->no_connect), 0);
|
||||
}
|
||||
|
||||
void perl_server_fill_hash(HV *hv, SERVER_REC *server)
|
||||
|
Loading…
Reference in New Issue
Block a user