[w32handle] Only own first handle if doing WaitHandle.WaitAny (#5625)
authorLudovic Henry <luhenry@microsoft.com>
Tue, 26 Sep 2017 03:05:58 +0000 (23:05 -0400)
committerGitHub <noreply@github.com>
Tue, 26 Sep 2017 03:05:58 +0000 (23:05 -0400)
commit932a58ea407d6878d610cbe516d901293977aba1
treef47309caececd9d8499157345d48bd3a6b388f7e
parent2d7b258eb95f64552d3118af545397003dcebfd6
[w32handle] Only own first handle if doing WaitHandle.WaitAny (#5625)

This is the behaviour on .NET, even if it goes against the documentation at https://msdn.microsoft.com/en-us/library/tdykks7z(v=vs.110).aspx#Anchor_2

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=59281
mono/metadata/w32handle.c
mono/tests/Makefile.am
mono/tests/bug-59281.cs [new file with mode: 0644]