AnyEvent and Strawberry perl issue
Laurent
laurent.aml at gmail.com
Fri Mar 13 16:36:34 CET 2015
On Fri, Mar 13, 2015 at 10:50 AM, Marc Lehmann <schmorp at schmorp.de> wrote:
>
> Working around this is hard now, as I would effectively do some fragile
> perl version + platform check to somehow invalidate perl's incorrect
> EINPROGRESS.
>
Given what you are saying, would the following be too naive?
(connect $state{fh}, $sockaddr)
# EINPROGRESS means something else entirely on Windows
|| ($! == Errno::EINPROGRESS && !AnyEvent::WIN32 # POSIX
|| $! == Errno::EWOULDBLOCK
# WSAEINPROGRESS intentionally not checked - it means
something else entirely
|| $! == AnyEvent::Util::WSAEINVAL # not convinced, but
doesn't hurt
|| $! == AnyEvent::Util::WSAEWOULDBLOCK)
I have not seen EINPROGRESS used much in AnyEvent (Coro::Handle has a
similar check, though).
-- Laurent
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.schmorp.de/pipermail/anyevent/attachments/20150313/d66b72e7/attachment.html>
More information about the anyevent
mailing list