gh-154324: Fix os.sendfile() error reporting on illumos (GH-154327) · python/cpython@e3634bb · GitHub
Skip to content

Commit e3634bb

Browse files
gh-154324: Fix os.sendfile() error reporting on illumos (GH-154327)
illumos sendfile(3EXT) returns the number of transferred bytes by adding it to the offset without initializing it, so the offset cannot be used to detect a partial write. Use sendfilev(3EXT), which reports the number of transferred bytes in an explicit out parameter. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 4f3e856 commit e3634bb

2 files changed

Lines changed: 26 additions & 15 deletions

File tree

Lines changed: 3 additions & 0 deletions

Modules/posixmodule.c

Lines changed: 23 additions & 15 deletions

0 commit comments

Comments
 (0)