Skip to content

Don't interpret unix.Pwrite()'s return value in case of errors - #355

Merged
EdSchouten merged 1 commit into
mainfrom
eschouten/20260725-pwrite
Jul 25, 2026
Merged

Don't interpret unix.Pwrite()'s return value in case of errors#355
EdSchouten merged 1 commit into
mainfrom
eschouten/20260725-pwrite

Conversation

@EdSchouten

Copy link
Copy Markdown
Member

The way pwrite() is defined in POSIX, there is no mechanism for returning both a size and an error. It's only either one of those. It looks like golang.org/x/sys does not explicitly return a length of zero in case of errors.

Reported by: Gregory Giecold in #159

The way pwrite() is defined in POSIX, there is no mechanism for
returning both a size and an error. It's only either one of those. It
looks like golang.org/x/sys does not explicitly return a length of zero
in case of errors.

Reported by: Gregory Giecold in #159
@EdSchouten
EdSchouten merged commit 2489d29 into main Jul 25, 2026
3 checks passed
@EdSchouten
EdSchouten deleted the eschouten/20260725-pwrite branch July 25, 2026 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants