|
|
c70942 |
diff -up nss/cmd/httpserv/httpserv.c.539183 nss/cmd/httpserv/httpserv.c
|
|
|
c70942 |
--- nss/cmd/httpserv/httpserv.c.539183 2016-08-15 17:58:41.756630037 +0200
|
|
|
c70942 |
+++ nss/cmd/httpserv/httpserv.c 2016-08-15 18:04:13.559131620 +0200
|
|
|
c70942 |
@@ -976,13 +976,13 @@ getBoundListenSocket(unsigned short port
|
|
|
c70942 |
PRNetAddr addr;
|
|
|
c70942 |
PRSocketOptionData opt;
|
|
|
c70942 |
|
|
|
c70942 |
- addr.inet.family = PR_AF_INET;
|
|
|
c70942 |
- addr.inet.ip = PR_INADDR_ANY;
|
|
|
c70942 |
- addr.inet.port = PR_htons(port);
|
|
|
c70942 |
+ if (PR_SetNetAddr(PR_IpAddrAny, PR_AF_INET6, port, &addr) != PR_SUCCESS) {
|
|
|
c70942 |
+ errExit("PR_SetNetAddr");
|
|
|
c70942 |
+ }
|
|
|
c70942 |
|
|
|
c70942 |
- listen_sock = PR_NewTCPSocket();
|
|
|
c70942 |
+ listen_sock = PR_OpenTCPSocket(PR_AF_INET6);
|
|
|
c70942 |
if (listen_sock == NULL) {
|
|
|
c70942 |
- errExit("PR_NewTCPSocket");
|
|
|
c70942 |
+ errExit("PR_OpenTCPSocket error");
|
|
|
c70942 |
}
|
|
|
c70942 |
|
|
|
c70942 |
opt.option = PR_SockOpt_Nonblocking;
|
|
|
c70942 |
diff -up nss/cmd/selfserv/selfserv.c.539183 nss/cmd/selfserv/selfserv.c
|
|
|
c70942 |
--- nss/cmd/selfserv/selfserv.c.539183 2016-08-15 17:58:41.756630037 +0200
|
|
|
c70942 |
+++ nss/cmd/selfserv/selfserv.c 2016-08-15 18:05:11.027487891 +0200
|
|
|
c70942 |
@@ -1731,13 +1731,13 @@ getBoundListenSocket(unsigned short port
|
|
|
c70942 |
PRNetAddr addr;
|
|
|
c70942 |
PRSocketOptionData opt;
|
|
|
c70942 |
|
|
|
c70942 |
- addr.inet.family = PR_AF_INET;
|
|
|
c70942 |
- addr.inet.ip = PR_INADDR_ANY;
|
|
|
c70942 |
- addr.inet.port = PR_htons(port);
|
|
|
c70942 |
+ if (PR_SetNetAddr(PR_IpAddrAny, PR_AF_INET6, port, &addr) != PR_SUCCESS) {
|
|
|
c70942 |
+ errExit("PR_SetNetAddr");
|
|
|
c70942 |
+ }
|
|
|
c70942 |
|
|
|
c70942 |
- listen_sock = PR_NewTCPSocket();
|
|
|
c70942 |
+ listen_sock = PR_OpenTCPSocket(PR_AF_INET6);
|
|
|
c70942 |
if (listen_sock == NULL) {
|
|
|
c70942 |
- errExit("PR_NewTCPSocket");
|
|
|
c70942 |
+ errExit("PR_OpenTCPSocket error");
|
|
|
c70942 |
}
|
|
|
c70942 |
|
|
|
c70942 |
opt.option = PR_SockOpt_Nonblocking;
|