Commit 2d97d12
committed
fix(cli): handle Windows EINVAL on broken-pipe flush
On Windows, flushing stdout after the reader closes the pipe raises
OSError EINVAL, not BrokenPipeError. Catch that case too so piping
help output to `head` exits cleanly instead of dumping a traceback.
Assisted-by: ClaudeCode:claude-opus-4.81 parent 69b4bf1 commit 2d97d12
1 file changed
Lines changed: 7 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
16 | 17 | | |
17 | 18 | | |
18 | 19 | | |
| |||
1028 | 1029 | | |
1029 | 1030 | | |
1030 | 1031 | | |
1031 | | - | |
1032 | | - | |
| 1032 | + | |
| 1033 | + | |
| 1034 | + | |
| 1035 | + | |
1033 | 1036 | | |
1034 | 1037 | | |
| 1038 | + | |
| 1039 | + | |
1035 | 1040 | | |
1036 | 1041 | | |
1037 | 1042 | | |
| |||
0 commit comments