Skip to content

x/sys/unix: export Fcntl and make more POSIX compliant #24677

@ppbrown

Description

@ppbrown

go version go1.10 linux/amd64

This is related to issue #24649 and thus to code review
https://go-review.googlesource.com/c/sys/+/104255

I am going to be attaching a new code PR to this issue. If accepted, I can then cancel the prior one.

It was discussed in 104255, how the potentially most clean approach is to finally export fcntl as Fcntl.

Unfortunately, the existing x/sys/unix.fcntl is not standards compliant with its type.
The third argument is declared as "int": however, sometimes, fcntl calls require the third argument to be a pointer.
This mandates that the third argument be changed to uintptr, rather than int.
Happily, it is currently an internal function only, so making the change does not require too many cascading updates.

Metadata

Metadata

Assignees

No one assigned

    Labels

    FrozenDueToAgeNeedsDecisionFeedback is required from experts, contributors, and/or the community before a change can be made.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions