File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -274,8 +274,6 @@ getAddrInfoNE hints node service = alloc getaddrinfo
274
274
ret <- c_getaddrinfo c_node c_service c_hints ptr_ptr_addrs
275
275
if ret == 0 then do
276
276
ptr_addrs <- peek ptr_ptr_addrs
277
- -- POSIX requires that getaddrinfo(3) returns at least one addrinfo.
278
- -- See: http://pubs.opengroup.org/onlinepubs/9699919799/functions/getaddrinfo.html
279
277
ais <- followAddrInfo ptr_addrs
280
278
return ais
281
279
else do
@@ -315,6 +313,8 @@ getAddrInfoList hints node service =
315
313
316
314
followAddrInfo :: Ptr AddrInfo -> IO (NonEmpty AddrInfo )
317
315
followAddrInfo ptr_ai
316
+ -- POSIX requires that getaddrinfo(3) returns at least one addrinfo.
317
+ -- See: http://pubs.opengroup.org/onlinepubs/9699919799/functions/getaddrinfo.html
318
318
| ptr_ai == nullPtr = ioError $ mkIOError NoSuchThing " getaddrinfo must return at least one addrinfo" Nothing Nothing
319
319
| otherwise = do
320
320
a <- peek ptr_ai
You can’t perform that action at this time.
0 commit comments