Commit d1ac44e
committed
fix: do not wrap io.EOF in errd.Wrap
Per the Go documentation, io.EOF must not be wrapped because callers
test for it using ==. The errd.Wrap helper wraps all non-nil errors,
including io.EOF, causing functions like Conn.reader to return
wrapped EOF errors that break standard EOF checks.
Skip wrapping when the error is io.EOF.
Fixes #5611 parent d099e16 commit d1ac44e
1 file changed
Lines changed: 4 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
9 | 10 | | |
| 11 | + | |
| 12 | + | |
10 | 13 | | |
11 | | - | |
| 14 | + | |
12 | 15 | | |
13 | 16 | | |
14 | 17 | | |
0 commit comments