From ba50a8e313d0be65559476700a893b18aae8c69f Mon Sep 17 00:00:00 2001 From: Stephen Toub Date: Mon, 24 Jun 2019 17:18:01 -0400 Subject: [PATCH] Revert "Tweak preferLocal value in System.Net.Sockets (dotnet/corefx#37369)" (dotnet/corefx#38829) This reverts commit dotnet/corefx@bf0fb29fb55cf4c3d9063c78e8f72fb9cd4d041b. Commit migrated from https://github.com/dotnet/corefx/commit/e2042dba58c522ab2dcc566a92c866b6186ce0dc --- .../src/System/Net/Sockets/SocketAsyncContext.Unix.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libraries/System.Net.Sockets/src/System/Net/Sockets/SocketAsyncContext.Unix.cs b/src/libraries/System.Net.Sockets/src/System/Net/Sockets/SocketAsyncContext.Unix.cs index d29e0e6..3ed34d2 100644 --- a/src/libraries/System.Net.Sockets/src/System/Net/Sockets/SocketAsyncContext.Unix.cs +++ b/src/libraries/System.Net.Sockets/src/System/Net/Sockets/SocketAsyncContext.Unix.cs @@ -255,7 +255,7 @@ namespace System.Net.Sockets // we can't pool the object, as ProcessQueue may still have a reference to it, due to // using a pattern whereby it takes the lock to grab an item, but then releases the lock // to do further processing on the item that's still in the list. - ThreadPool.UnsafeQueueUserWorkItem(s => s.InvokeCallback(allowPooling: false), this, preferLocal: true); + ThreadPool.UnsafeQueueUserWorkItem(o => ((AsyncOperation)o).InvokeCallback(allowPooling: false), this); } Trace("Exit"); @@ -276,7 +276,7 @@ namespace System.Net.Sockets else { // Async operation. Process the IO on the threadpool. - ThreadPool.UnsafeQueueUserWorkItem(this, preferLocal: true); + ThreadPool.UnsafeQueueUserWorkItem(this, preferLocal: false); } } -- 2.7.4