mirror of
https://github.com/weechat/weechat.git
synced 2026-06-12 14:14:48 +02:00
relay/api: free hook_url_handshake when disconnecting from remote
This commit is contained in:
@@ -81,16 +81,22 @@ relay_remote_network_close_connection (struct t_relay_remote *remote)
|
||||
{
|
||||
if (!remote)
|
||||
return;
|
||||
if (remote->hook_fd)
|
||||
|
||||
if (remote->hook_url_handshake)
|
||||
{
|
||||
weechat_unhook (remote->hook_fd);
|
||||
remote->hook_fd = NULL;
|
||||
weechat_unhook (remote->hook_url_handshake);
|
||||
remote->hook_url_handshake = NULL;
|
||||
}
|
||||
if (remote->hook_connect)
|
||||
{
|
||||
weechat_unhook (remote->hook_connect);
|
||||
remote->hook_connect = NULL;
|
||||
}
|
||||
if (remote->hook_fd)
|
||||
{
|
||||
weechat_unhook (remote->hook_fd);
|
||||
remote->hook_fd = NULL;
|
||||
}
|
||||
if (remote->sock != -1)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
|
||||
Reference in New Issue
Block a user