diff options
| author | Bryan C. Mills <bcmills@google.com> | 2021-12-10 14:13:52 -0500 |
|---|---|---|
| committer | Bryan Mills <bcmills@google.com> | 2021-12-13 16:44:13 +0000 |
| commit | acc65b47e12e2ba061b8ab4f86b183d039072776 (patch) | |
| tree | 0f8d80eb60808600851586668a92225e1ccf381a /src/cmd/nm | |
| parent | 4b3d8d1a390a51ea6a1b3f66ef9d56ef7203bbe7 (diff) | |
| download | go-acc65b47e12e2ba061b8ab4f86b183d039072776.tar.xz | |
net: refactor TestWriteToTimeout
The test cases for this test had listed specific errors, but the
specific error values were ignored in favor of just calling
isDeadlineExceeded.
Moreover, ENOBUFS errors (which can legitimately occur in the test if
the network interface also happens to be saturated when the timeout
occurs) were not handled at all.
Now the test relies only on the timeout: we iterate until we have seen
two of the expected timeout errors, and if we see ENOBUFS instead of
"deadline exceeded" we back off to give the queues time to drain.
Fixes #49930
Change-Id: I258a6d5c935d9635b02dffd79e197ba9caf83ac8
Reviewed-on: https://go-review.googlesource.com/c/go/+/370882
Trust: Bryan Mills <bcmills@google.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Bryan Mills <bcmills@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Diffstat (limited to 'src/cmd/nm')
0 files changed, 0 insertions, 0 deletions
