On Wed, 01 Feb 2017 13:11:21 -0800, j...@gellyfish.co.uk wrote:
> With 6.d.PREVIEW the simplest code for IO::Socket::Async mis-behaves:
> 
>     use v6.d.PREVIEW;
> 
>     react {
>         whenever IO::Socket::Async.listen('localhost', 3333) -> $conn {
>             whenever $conn.Supply(:bin) -> $buf {
>                 await $conn.write: $buf;
>                 $conn.close;
>             }
>         }
>     }
> 
> Gives rise to:
> 
>     Unhandled exception in code scheduled on thread 7
>     Attempt to unlock mutex by thread not holding it
> 
> After the second connection every time.  I noticed this when testing
> HTTP::Server::Tiny.
> 
> This is Rakudo version 2017.01-132-g97359ae built on MoarVM version
> 2017.01-25-g70d4bd5

Fixed now, and test coverage of this, and the deeper underlying issue, is in 
S17-promise/nonblocking-await.t.

Reply via email to