* Moving SafeWaitHandle to shared
* Moved CancellationToken to shared
* _ remove from variable names
* Default change to Default(Token) and minor changes
* Fixing coreclr unix build
* moving semaphoreSlim to shared
* splitting safeWaitHandle to .windows and .unix
Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
* build stub assemblies on FreeBSD from *UnknownUnix*
* feedback from review. move RegisterNetworkChange to common file
* use netcoreapp-Unix for FreeBSD until we have real implementation
* add option to handle TTL for raw socket and system utility
* add missing blank line
* incorporate feedback and merge with upstream
* feedback from review
* Use public implementation MarshalSupport
* Implement NotifyCollectionChangedEventArgsMarshaler ConvertToManaged and PropertyChangedEventArgsMarshaler ConvertToNative
* Refactor RoGetActivationFactory into Common
* Update according to comments and add an analyzerdata file
* Move NtProcessInfoHelper to ProcessManager.Win32.cs
NtProcessInfoHelper was split between ProcessManager.Win32.cs and ProcessManager.Windows.cs for no good reason
* Update performance counter interop to use Span<T>
This is both faster and more secure
* Delete FEATURE_TRACESWITCH
* Don't write a separator after the empty DN
* Make T61String behave like it does on Windows (UTF-8 with a Latin-1 fallback)
* Use the managed decoder on Linux, instead of a lot of P/Invokes back into OpenSSL.
This removes a great deal of the unneeded allocations in GraphicsPath and Graphics. Points and rectangles match the native types exactly and don't need special marshalling outside of pinning arrays.
This removes all usages of GPPOINT/F. Many GPRECT/F usages were removed, but still exist in other classes.
Make a consistency pass through Graphics & GraphicsPath.
Plan is to follow up with a change that removes the rest of the unnecessary allocations.
This change focuses on the Windows specific code. Some Unix code will be able to be unified with the Windows code once further changes happen. Rather than reformat the Unix code preemptively, leaving for final follow-up.
* Removed AccessControl Unused arguments
* moving common code to CreateEventCore and using constructor chaining
* Moving Functions to eventwaithandles.windows
* EventWaitHandle matched with corert
* eventwaithandle.windwos matched with corert
* Addding interop functions
* moved files to shared
* Minor changes
* fixing build for corert unix
* Removing Comment
Signed-off-by: dotnet-bot-corefx-mirror <dotnet-bot@microsoft.com>
When `CancelChildren` is enabled (currently only in the `TaskCancelWait1` test)
we're hitting a race in `TaskCancelWaitTest.CreateTask()`:
1. Let's assume Task A is processing `node`
2. Task A spawns a new Task B for processing `node_1`
3. Task B starts and signals the `_countdownEvent`
4. `RealRun()` on the main thread exits the wait on `_countdownEvent`
5. `RealRun()` calls `Verify()` which loops through all the nodes and calls `VerifyCancel()`
6. We get an assertion because `CancellationToken.IsCancellationRequested` is false
7. Task A continues and sets the CancellationToken, but it is already too late by this point
To fix this race we wait on the task in `RealRun()` before proceeding to
the verification step.
This uncovered another issue:
Since `_countdownEvent` is accessed by multiple threads we have another
race between checking `_countdownEvent.IsSet` and `_countdownEvent.Signal()`.
This caused a `System.InvalidOperationException: Invalid attempt made to decrement the event's count below zero.`
Fixed it by locking access to the `_countdownEvent`.
Fixes https://github.com/dotnet/corefx/issues/20457
Fixes https://github.com/mono/mono/issues/6920