From e4cf140f8a0dfc10c9830f2dc69bd4231cb275f6 Mon Sep 17 00:00:00 2001 From: Darren VanBuren Date: Sun, 23 Jul 2017 08:12:48 -0700 Subject: [PATCH] Got connected by calling htons on port num --- main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.cpp b/main.cpp index 45d3c93..69f90e7 100644 --- a/main.cpp +++ b/main.cpp @@ -105,7 +105,7 @@ int main(int argc, char *argv[]) { PRFileDesc *tcpSocket = PR_OpenTCPSocket(PR_AF_INET6); PRFileDesc *model = PR_NewTCPSocket(); - theAddr.ipv6.port = 443; + theAddr.ipv6.port = PR_htons(443); theAddr.raw.family = PR_AF_INET6; PRFileDesc *nssSocket; PRFileDesc *sslModel = SSL_ImportFD(NULL, model);