-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Fix (Http)WebRequest (Begin|End)GetResponse samples #11030
Conversation
Tagging subscribers to this area: @dotnet/ncl |
Learn Build status updates of commit b3b4b42: ✅ Validation status: passed
For more details, please refer to the build report. For any questions, please:
|
Learn Build status updates of commit ea80921: ✅ Validation status: passed
For more details, please refer to the build report. For any questions, please:
|
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.
Thank you!
These samples were not handling the
asyncResult.CompletedSynchronously == true
case correctly: changing the sample code to use smaller buffer leads to stack overflow because of recursion on synchronous completions.Besides the fix there the PR adds some consolidation:
WebRequest.Timeout
insteadHttpWebRequest
andWebRequest
samples since they are practically identicalFixes #8662