Skip to content

Commit 36b22fe

Browse files
committed
Added the check if the process has exited to the synchronies process execution
1 parent 671d25a commit 36b22fe

2 files changed

Lines changed: 37 additions & 46 deletions

File tree

src/WGet.NET/Components/Internal/ProcessManager.cs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,13 @@ private ProcessResult RunProcess(ProcessStartInfo processStartInfo)
118118

119119
//Wait till end and get exit code
120120
proc.WaitForExit();
121+
122+
// Make sure the process has exited
123+
if (!proc.HasExited)
124+
{
125+
proc.Kill();
126+
}
127+
121128
result.ExitCode = proc.ExitCode;
122129
}
123130

src/WGet.NET/XmlDocumentation/WGet.NET.xml

Lines changed: 30 additions & 46 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)