Fixes tasyncawait and the net module on Linux.

This commit is contained in:
Dominik Picheta 2014-03-23 11:39:24 +00:00
commit 10f205bb52
2 changed files with 3 additions and 2 deletions

View file

@ -22,7 +22,8 @@ when defined(Windows):
export WSAEWOULDBLOCK export WSAEWOULDBLOCK
else: else:
import posix import posix
export fcntl, F_GETFL, O_NONBLOCK, F_SETFL, EAGAIN, EWOULDBLOCK export fcntl, F_GETFL, O_NONBLOCK, F_SETFL, EAGAIN, EWOULDBLOCK, MSG_NOSIGNAL,
EINTR, EINPROGRESS
export TSocketHandle, TSockaddr_in, TAddrinfo, INADDR_ANY, TSockAddr, TSockLen, export TSocketHandle, TSockaddr_in, TAddrinfo, INADDR_ANY, TSockAddr, TSockLen,
inet_ntoa, recv, `==`, connect, send, accept, recvfrom, sendto inet_ntoa, recv, `==`, connect, send, accept, recvfrom, sendto

View file

@ -3,7 +3,7 @@ discard """
cmd: "nimrod cc --hints:on $# $#" cmd: "nimrod cc --hints:on $# $#"
output: "5000" output: "5000"
""" """
import asyncio2, sockets2, net, strutils, os import asyncdispatch, rawsockets, net, strutils, os
var disp = newDispatcher() var disp = newDispatcher()
var msgCount = 0 var msgCount = 0