Age | Commit message (Collapse) | Author |
|
* Credentials fixes
* remove dead code
* Update PostScenarioTest.cs
Revert variable name
|
|
|
|
|
|
|
|
* Fix Process.ExitCode on mac for killed processes
https://github.com/dotnet/corefx/pull/26291 changed process reaping
from using waitpid to waitid. This caused a regression on mac, since
for processes that are killed, (on mac) waitid does not return the
signal number that caused the process to terminated.
We change back to waitpid for reaping children and determining the
exit code. waitid is used to find terminated children.
Fixes https://github.com/dotnet/corefx/issues/29370
* TestExitCodeKilledChild: remove runtime check
* TestExitCodeKilledChild: remove greater than assert
|
|
|
|
Fixes: #28668
|
|
|
|
|
|
|
|
* ProcessWaitState: support recycled child pids
* Ensure ProcessWaitHandle uses same ProcessWaitState as Process
* Fix race between Close and CompletionCallback
* Revert GetWaitState
* Add test
* Handle race between Close and CompletionCallback
|
|
|
|
|
|
|
|
|
|
* Process.StartTime on Linux - make it deterministic & compatible with other languages/frameworks, e.g. with Python's psutil.Process.create_time
* Added test for Process.StartTime being deterministic across process instances
* Add note about btime, changed Process.BootTime to be a property which is always calcualted, made "Process.StratTime deterministic across instances" test to be Linux-specific
* Removed unused ProcUptimeFilePath. Changed test to use PlatformSpecific instead of being in separate file
* bttime - parse as 32-bit integer
* Adjustments/fixes after code review
* Adjustments after code review
|
|
This makes it a bit smaller, faster and allocate less. And also make it compile with CoreRT.
|
|
Fixes https://github.com/dotnet/corert/issues/5593
|
|
|
|
|
|
Update SLNs and projects to be in sync with configurations
|
|
|
|
async (#27850)
* TestChildProcessCleanupTest, TestProcessWaitStateReferenceCount: increase timeout from 1s to 30s; sleep async
* PR feedback
|
|
System.Diagnostics.Tests.ProcessTests/ProcessStart_UseShellExecuteTrue_OpenMissingFile_Throw (#27557)
Related to #27547
* Wrapping Process.Start with missing using statement
* remove confusing/incorrect comment
* Undo add using statement when asserting exception throws
* Assert process is not null
* HasWindowsShell should also satisfy IsWindows condition
* update existingt tests
* Removing unnecessary exception variable
|
|
* Fixing System.Diagnostics.Tests.ProcessTests failures on Unix
Making sure we throw InvalidOperationException and with proper message to be consistent with netfx.
This fixes test HandleCountChanges and updates two other existing tests
Making s_allowedProgramsToRun field static in order to fix the 'field marshalling' error occuring during RemoteInvoke
Fixes #27459
* Changing back to existing exception type and correcting the test method accordingly
|
|
SystemEvents
|
|
|
|
* Separate signal handling from console implementation
* Pass SIGCHLD to SignalHandlerLoop
* Move lock to native code
* Add sigchld callback
* Reap children on SIGCHLD
* Reap child on unsuccesful ForkAndExecProcess
* ResumeSigChld: improve comment and fix build
* Handle iterator becoming invalid while reaping children
* Fix comments
* pal_signal.cpp -> pal_signal.c
* Throw Win32Exception when InitializeSignalHandling fails
* Fix alpine build: missing C void arguments
* Remove ResumeSigChld
* Call InitializeSignalHandling from InitializeConsoleInitializeConsole and RegisterForSigChldRegisterForSigChld
* Use ReaderWriterLock to allow multiple Processes to start concurrently
* throw Win32Exception when InitializeConsole fails
* PR feedback
* Implement SystemNative_WaitPid using waitid to check OS support
* Fix WaitPid waitid implementation
* Replace WaitPid with WaitIdExitedNoHang
* Optimize child reaping by asking OS what children terminated instead of iterating
* Implement WaitForExit for children using ManualResetEvent
* Remove SystemNative_W{ExitStatus,IfExited,IfSignaled,TermSig}
* Don't spin up wait loop for children
* Don't create ManualResetEvent when the child has already exited
* Add TestChildProcessCleanup test
* TestChildProcessCleanup: 'uname' is not at '/usr/bin' on Debian systems
* Fix multiple assignments of _waitStateHolder
* Add TestProcessWaitStateReferenceCount
* FailFast when waitid gives an unexpected return
* ProcessWaitHandle: let ProcessWaitState dispose the handle
* TestProcessWaitStateReferenceCount: fix test, need to WaitForExit otherwise Dispose cancels Exited event
* Add TestChildProcessCleanupAfterDispose
* TestProcessWaitStateReferenceCount: add retry+sleep
|
|
This commit does several things:
- Exposes the new `ValueTask` extensibility model being added in coreclr. The ValueTask-related files will separately be mirrored over to corefx to enable the netstandard build of System.Threading.Tasks.Extensions.
- Adapts all `Stream`-derived types to return `ValueTask` instead of `Task` from `WriteAsync`.
- Changes the new `WebSocket` `SendAsync` method to return `ValueTask` instead of `Task`, and updates the `ManagedWebSocket` implementation accordingly. Most `SendAsync`s on `ManagedWebSocket` should now return a `ValueTask` that's either completed synchronously (no allocation) or using a pooled object. It now uses the underlying transport's new `WriteAsync` overload that returns `ValueTask`.
- Switches more uses of `ReadAsync` and `WriteAsync` over to the new overloads, including in Process, DeflateStream, BrotliStream, File, HttpClient, SslStream, WebClient, BufferedStream, CryptoStream,
- Removed some unnecessary array clearing from various routines using ArrayPool (after the clearing was added we changed our minds and decided clearing was only necessary in very specific circumstances)
- Implements a custom `IValueTaskSource` in Socket, such that async receives and sends become allocation-free (ammortized). `NetworkStream` then inherits this functionality, such that its new `ReadAsync` and `WriteAsync` are also allocation-free (in the unbounded channel implementations; we can subsequently add it in for bounded).
- Implements a custom `IValueTaskSource` in System.Threading.Channels, such that reading and writing are ammortized allocation-free up to one concurrent reader and writer.
- A few random things I noticed as I was going through, e.g. missing ConfigureAwait, some incorrect synchronization in tests, etc.
- Adds a ton of new tests, mainly in System.Threading.Tasks.Extensions, System.Threading.Channels, and System.Net.Sockets.
|
|
|
|
* Fix outerloop in System.Runtime.Extensions
* Add back finalizer to call Dispose(false)
* Fixing Dispose issue on Unix.
Also making code style consistent in ProcessTestBase by having a using statement to work with RemoteInvokeHandle
* Remove comment
|
|
|
|
The fix for https://github.com/dotnet/corefx/issues/27426 unmasked hidden failing tests.
|
|
* Rename string-slicing extension methods
As part of
https://github.com/dotnet/corefx/issues/26894
the api folks have approved renaming AsROSpan and AsROMemory
on string instances to AsSpan and AsMemory (as the "readonly"
is obvious given the read-only nature of the input.)
This puts the renaming in effect. Basically a big search-replace
commit.
* Fix OpenSSL build break
* I see this is going to be a treadmill
|
|
* Try finalizer on RemoteInvokeHandle
* Adding missing Dispose call to RemoteInvoke's in different test projects
* Fixing tests in System.Diagnostics.Process missing Dispose on RemoteInvokeHandle
* Add missing Dispose call to System.Data.Common.XsdSchemaDeserializationIgnoresLocale()
* Fixing netfx failure in System.Runtime
* Adding missing Dispose call after using RemoteInvokeHandle in System.Net.ServicePoint project
|
|
Get the real user name in the test process, not the child process. The outerloop tests are run with 'sudo'. Which means by the time we are in the child process SUDO_USER will be set to 'root', since the parent test process was run with 'sudo'.
Fixes #26675
|
|
By default, 1K is too large of a buffer to allocate on the stack.
Fixes #26959
|
|
|
|
There is a bug in CentOS7.1 getpwnam_r where it returns the wrong value if you pass in a buffer that is too small to hold the data. In Debug builds, we are purposefully passing in a buffer that is too small to test the fallback code, which is running into this OS bug.
See https://bugs.centos.org/view.php?id=7324
Fixes #26673
|
|
|
|
ProjectNTfsTestILC to prerelease-02430-04, preview2-26130-05, preview2-26130-01, preview2-26129-06, beta-26130-01, beta-26130-01, respectively (master) (#26631)
* Update BuildTools, CoreClr, CoreFx, CoreSetup, ProjectNTfs, ProjectNTfsTestILC to prerelease-02430-04, preview2-26130-05, preview2-26130-01, preview2-26129-06, beta-26130-01, beta-26130-01, respectively
* Undoing BuildTools update
* Skipping test causing UAP test run to crash for Process
|
|
* Support Process.Start as a different user on Unix.
The most common use case is to de-escalate privileges from a privileged process to a normal process.
Part of #26268
* Address PR feedback
|
|
* Command line tokenization reconciling
Using PasteArguments from Environment to avoid code duplication while
getting command line.
Issue #21267. Command Line tokenization is done all over the place and inconsistently.
* Fixing no-op bug. Clean up (style)
* Paste arguments cross platform fix: avoiding arg[0] check on Unix. refs #25857
* Fixing code style. Adding unit tests. Refs #25857
* (UWP CoreCLR x64 build fix)
|
|
|
|
|
|
If the process pipes for stdin/stdout/stderr are not touched by the user, dispose of them.
Partial fix to #25962
|
|
|
|
* Add StandardInputEncoding to ProcessStartInfo
* Add test coverage for ProcessStartInfo.StandardInputEncoding
* Add unix support for ProcessStartInfo.StandardInputEncoding
* Clean up StandardInputEncoding implementation
* Incorporate feedback from https://github.com/dotnet/corefx/pull/25990 for ProcessStartInfo.StandardInputEncoding feature.
* ProcessStartInfo.StandardInputEncoding: skip two unsupported tests on UAP
|
|
packages (#25921)
* Add System.Drawing.Common to netcoreapp vertical
* Make System.Data.Odbc be able to build for netcoreapp vertical
* Add netcoreapp to System.Diagnostics.PerformanceCounter
* Add netcoreapp to System.Diagnostics.EventLog
* Run UpdateVSConfigurations
* Change Contains('netcoreapp') to StartsWith('netcoreapp')
* Include netcoreapp.depproj only when BuildAllConfigurations == true
* Change tests to netcoreapp from netcoreapp2.0 for vertical
|
|
Add useful comment raised during code review of PR 21339
|