Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
os/user: fix signedness of UIDs before stringifying #22739
Comments
|
We can fix os/user's User.Uid, but the Go 1 compatibility promise prevents us from changing the syscall.Getuid signature. You'll have to convert there. But it's the syscall package anyway, so people are expected to roll up their sleeves a bit. |
bradfitz
changed the title from
`getuid` and co return signed integers; hilarity ensues
to
os/user: fix signedness of UIDs before stringifying
Nov 15, 2017
bradfitz
added
the
NeedsFix
label
Nov 15, 2017
bradfitz
added this to the Go1.10 milestone
Nov 15, 2017
|
note the same applies to |
|
also, in case you're wondering, uids and gids of 0xffffffff aren't allowed because -1 is used as a flag to mean 'no change' for |
gopherbot
commented
Nov 15, 2017
|
Change https://golang.org/cl/77930 mentions this issue: |
|
I handled gid in https://go-review.googlesource.com/#/c/go/+/77930 too. |
bradfitz
self-assigned this
Nov 15, 2017
gopherbot
closed this
in
7edb721
Nov 16, 2017
chipaca
referenced this issue
in snapcore/snapd
Nov 22, 2017
Closed
osutil/user: replace our uses of os/user and filepath.Glob("/home/*") #4277
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
chipaca commentedNov 15, 2017
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (
go version)?at least 1.6 and 1.9 (haven't checked elsewhere)
Does this issue reproduce with the latest release?
that's 1.9, right?
What operating system and processor architecture are you using (
go env)?issue is with 32 bit Linux, only (so
GOARCHof386andarm, andppc)What did you do?
given
and
and
What did you expect to see?
What did you see instead?