summaryrefslogtreecommitdiff
path: root/src/fe-common/core
diff options
context:
space:
mode:
authorLemonBoy <thatlemon@gmail.com>2015-09-21 13:54:13 +0200
committerLemonBoy <thatlemon@gmail.com>2015-09-21 14:19:35 +0200
commitffaa890e99e2176ff3d2dec0ab5a8136e1e946ff (patch)
tree8c3765d9736a0f86037b42c18fd3c1553b4a2434 /src/fe-common/core
parent0912a1105058829559529e2ae7d62daccb8337f6 (diff)
downloadirssi-ffaa890e99e2176ff3d2dec0ab5a8136e1e946ff.zip
Initial work to make irssi respect the resolved ip order
Ip's aren't selected using random() anymore, also select the ip version by using getaddrinfo and some proper hints.
Diffstat (limited to 'src/fe-common/core')
-rw-r--r--src/fe-common/core/fe-server.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/fe-common/core/fe-server.c b/src/fe-common/core/fe-server.c
index 429e6dac..f8558ad1 100644
--- a/src/fe-common/core/fe-server.c
+++ b/src/fe-common/core/fe-server.c
@@ -138,7 +138,7 @@ static void cmd_server_add(const char *data)
if (*password != '\0') g_free_and_null(rec->password);
if (g_hash_table_lookup(optlist, "host")) {
g_free_and_null(rec->own_host);
- rec->own_ip4 = rec->own_ip6 = NULL;
+ rec->own_ip = NULL;
}
}
@@ -193,7 +193,7 @@ static void cmd_server_add(const char *data)
value = g_hash_table_lookup(optlist, "host");
if (value != NULL && *value != '\0') {
rec->own_host = g_strdup(value);
- rec->own_ip4 = rec->own_ip6 = NULL;
+ rec->own_ip = NULL;
}
signal_emit("server add fill", 2, rec, optlist);