-
Notifications
You must be signed in to change notification settings - Fork 401
SuggestionStore::GetCompletions to check exit code of invoked applica… #2160
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 1 commit
d3e8b47
1c23816
65a92f5
d8adba7
8b8e3b7
8895dfd
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -44,7 +44,7 @@ public string GetCompletions(string exeFileName, string suggestionTargetArgument | |
|
||
Task<string> readToEndTask = process.StandardOutput.ReadToEndAsync(); | ||
|
||
if (readToEndTask.Wait(timeout)) | ||
if (readToEndTask.Wait(timeout) && process.HasExited && process.ExitCode == 0) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm not sure this is entirely reliable. If the child process first closes its standard output and then exits, then |
||
{ | ||
result = readToEndTask.Result; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The
else
block might need some additional checks as well. It doesn't appear that we have code coverage over both of these code branches.