aboutsummaryrefslogtreecommitdiffstats
path: root/kirc.c
diff options
context:
space:
mode:
authorMichael Czigler <37268479+mcpcpc@users.noreply.github.com>2020-09-15 13:06:59 -0400
committerGitHub <noreply@github.com>2020-09-15 13:06:59 -0400
commit0b0087074ea6d273bc58733280f38465f870c35e (patch)
tree3880683a3a41c1747b51503a5a1ea717052647ef /kirc.c
parentMerge pull request #19 from vainiovano/master (diff)
downloadkirc-0b0087074ea6d273bc58733280f38465f870c35e.tar.gz
kirc-0b0087074ea6d273bc58733280f38465f870c35e.tar.bz2
kirc-0b0087074ea6d273bc58733280f38465f870c35e.tar.xz
kirc-0b0087074ea6d273bc58733280f38465f870c35e.tar.zst
kirc-0b0087074ea6d273bc58733280f38465f870c35e.zip
replace AF_INET with AF_UNSPEC
Diffstat (limited to 'kirc.c')
-rw-r--r--kirc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/kirc.c b/kirc.c
index f60590c..5a11817 100644
--- a/kirc.c
+++ b/kirc.c
@@ -66,7 +66,7 @@ static int
irc_init() {
struct addrinfo *res, hints = {
- .ai_family = AF_INET,
+ .ai_family = AF_UNSPEC,
.ai_socktype = SOCK_STREAM
};
int gai_status;
@@ -93,8 +93,8 @@ irc_init() {
freeaddrinfo(res);
if (p == NULL) {
- fputs("Failed to connect\n", stderr);
- return -1;
+ fputs("Failed to connect\n", stderr);
+ return -1;
}
fcntl(conn, F_SETFL, O_NONBLOCK);