Commit graph

24 commits

Author SHA1 Message Date
Araq
41385f3aaf made a test green 2015-02-12 14:56:57 +01:00
Elie Zedeck
1845e05a34 Handle EPOLLHUP to avoid chaos/runaways when using certain file descriptors.
A concrete example is pipe file descriptors: they generate EPOLLHUP instead of a EPOLLIN (then 0 bytes read). The loop will run wild if this event is not handled.
2015-01-21 18:15:38 +03:00
def
519ec304e4 Fix: Only handle EPOLLERR as an error event
When an EPOLLRDHUP is received with epoll_ctl, there can still be data
to be read. So we shouldn't immediately close the socket and abort.
2015-01-13 00:45:17 +01:00
Guillaume Gelin
3119fe087d Happy new year! 2015-01-06 15:26:33 +01:00
def
f56dcd1505 Handle interrupt on epoll_wait graciously (allows strace to work) 2015-01-04 23:07:21 +01:00
def
d60d007281 Close async socket on error (instead of looping on epoll_wait with 100% CPU) 2015-01-04 22:59:41 +01:00
Araq
7333237be6 'nimfix' improvements; FdSet is TFdSet again 2014-09-08 08:46:35 +02:00
Araq
11b6958755 big rename 2014-08-27 23:42:51 +02:00
Dominik Picheta
cf5c8a204e Many async optimisations.
* Selectors implementation will now attempt to immediately execute an IO
  operation instead of waiting for a ready notification.
* Removed recursion in asynchttpserver.
* Improved buffered implementation of recvLine in asyncnet.
* Optimised ``respond`` in asynchttpserver removing a possible "Delayed ACK"
  situation.
2014-07-12 22:51:06 +01:00
Varriount
1d6c05edc3 Update selectors.nim 2014-05-25 12:20:24 -04:00
Varriount
f10f9c4b7e Update selectors.nim
Fixed selectors.nim on macosx
2014-05-25 11:35:10 -04:00
Clay Sweetser
0dc770332e Fix issue #1134
Adds the necessary imports for selectors under MacOSX
2014-05-24 09:12:07 -04:00
Dominik Picheta
e54ab22bf9 Fixes #1197. 2014-05-14 23:35:46 +01:00
Dominik Picheta
941cc937d3 Fixes docgen. 2014-04-15 22:09:12 +01:00
Dominik Picheta
21d0cc8cdf Add checks for invalid socket when creating sockets. 2014-04-15 13:51:25 +01:00
Dominik Picheta
61c9c429d4 Fixes selectors module on Mac OS X. 2014-04-06 23:20:55 +01:00
Dominik Picheta
d98b0d9f79 Selectors module now uses select on operating systems other than Linux. 2014-04-06 21:43:51 +01:00
Dominik Picheta
5eaec84785 Select implementation in selectors module compiles again. 2014-04-06 19:27:47 +01:00
Dominik Picheta
1a75b17cd0 File descriptors are now removed from fds list explicitly in close().
Fixes tasyncawait on linux.
2014-03-14 18:46:08 +00:00
Dominik Picheta
2ce07042fd tasyncawait now works on Linux.
Reworked detection of a file descriptor being closed with epoll (in the
case of sockets it is when the remote host disconnects). Ensured that
events are only updated when they change.
2014-03-11 21:53:35 +00:00
Dominik Picheta
a097526956 Fixes to asyncio2 on Linux. 2014-03-09 13:49:38 +00:00
Dominik Picheta
3b5825e9bc Implemented selector support for asyncio2. 2014-02-22 17:22:19 +00:00
Dominik Picheta
471c0aa634 Epoll now works. 2013-10-31 15:07:14 +00:00
Dominik Picheta
526f9da463 Epoll wrapper + selectors module. 2013-10-31 02:45:17 +00:00