diff options
Diffstat (limited to 'tests/async/tasyncdial.nim')
-rw-r--r-- | tests/async/tasyncdial.nim | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/tests/async/tasyncdial.nim b/tests/async/tasyncdial.nim index fa81235fe..f0377dfd5 100644 --- a/tests/async/tasyncdial.nim +++ b/tests/async/tasyncdial.nim @@ -1,20 +1,18 @@ discard """ - file: "tasyncdial.nim" output: ''' OK AF_INET OK AF_INET6 ''' - disabled: "travis" """ import nativesockets, os, asyncdispatch proc setupServerSocket(hostname: string, port: Port, domain: Domain): AsyncFD = - ## Creates a socket, binds it to the specified address, and starts listening for connecitons. + ## Creates a socket, binds it to the specified address, and starts listening for connections. ## Registers the descriptor with the dispatcher of the current thread ## Raises OSError in case of an error. - let fd = newNativeSocket(domain) + let fd = createNativeSocket(domain) setSockOptInt(fd, SOL_SOCKET, SO_REUSEADDR, 1) var aiList = getAddrInfo(hostname, port, domain) if bindAddr(fd, aiList.ai_addr, aiList.ai_addrlen.Socklen) < 0'i32: |