Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

os: plan9: sometimes stat has too short of a buffer #8781

Closed
gopherbot opened this issue Sep 19, 2014 · 4 comments
Closed

os: plan9: sometimes stat has too short of a buffer #8781

gopherbot opened this issue Sep 19, 2014 · 4 comments

Comments

@gopherbot
Copy link

by mischief@offblast.org:

Before filing a bug, please check whether it has been fixed since the
latest release. Search the issue tracker and check that you're running the
latest version of Go:

Run "go version" and compare against
http://golang.org/doc/devel/release.html  If a newer version of Go exists,
install it and retry what you did to reproduce the problem.

Thanks.

What does 'go version' print?
go version devel +67bbd0083f7d Fri Sep 19 14:13:51 2014 -0700 plan9/amd64

What steps reproduce the problem?
If possible, include a link to a program on play.golang.org.

go test -v -a -run TestAll cmd/gofmt

What happened?

--- FAIL: TestAll (12.87s)
    long_test.go:106: stat /sys/src/go/.hg/store/data/doc/articles/go__concurrency__patterns__timing__out__moving__on.html.i: stat buffer too short
    long_test.go:106: stat /sys/src/go/.hg/store/data/src/crypto/tls/testdata/_client-_t_l_sv10-_client_cert-_e_c_d_s_a-_e_c_d_s_a.i: stat buffer too short
    long_test.go:106: stat /sys/src/go/.hg/store/data/src/crypto/tls/testdata/_client-_t_l_sv10-_client_cert-_e_c_d_s_a-_r_s_a.i: stat buffer too short
    long_test.go:106: stat /sys/src/go/.hg/store/data/src/crypto/tls/testdata/_client-_t_l_sv10-_client_cert-_r_s_a-_e_c_d_s_a.i: stat buffer too short

.....

What should have happened instead?
--- PASS: TestAll (11.96s)
PASS
ok      cmd/gofmt   11.968s

Please provide any additional information below.
stat_plan9.go always errors out if stat returns an error. stat on plan 9 can return an
error, but you must check the size of the buffer returned to determine if you should try
again with a larger stat buffer. it should do as plan 9 libc does.
@ianlancetaylor
Copy link
Contributor

Comment 1:

Labels changed: added repo-main, release-none, os-plan9.

@gopherbot
Copy link
Author

Comment 2:

CL https://golang.org/cl/150730043 mentions this issue.

@0intro
Copy link
Member

0intro commented Jan 8, 2015

Nick Owens submitted a fix for this issue.

https://codereview.appspot.com/150730043/

However, it wasn't merged in the tree.

@0intro
Copy link
Member

0intro commented Jan 8, 2015

CC @mischief

@0intro 0intro closed this as completed in 2a74f43 Jan 26, 2015
@golang golang locked and limited conversation to collaborators Jun 25, 2016
@rsc rsc unassigned 0intro Jun 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants