-
Notifications
You must be signed in to change notification settings - Fork 17.7k
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
x/mod/sumdb/dirhash: panic observed traversing tmp dir #57269
Comments
This occurs any time the argument to The bug is here: The error is the assumption that The fix is probably to return an explicit error if the argument |
Thanks for the insight. I’ll try to put a fix together. |
This patch fixes a case where a path to a non directory can cause DirHash func to panic. Fixes: golang/go#57269 Signed-off-by: Simar <simar@linux.com>
I've created a PR to address this here: golang/mod#16 |
This patch fixes a case where a path to a non directory can cause DirHash func to panic. Fixes: golang/go#57269.
This patch fixes a case where a path to a non directory can cause DirHash func to panic. Fixes: golang/go#57269.
This patch fixes a case where a path to a non directory can cause DirHash func to panic. Fixes: golang/go#57269.
Change https://go.dev/cl/457075 mentions this issue: |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
What did you expect to see?
No panic
What did you see instead?
Panic
Few extra observations:
/tmp/
is passed as a param. The perms on the/tmp
dir on macOS:ls -lrth /tmp lrwxr-xr-x@ 1 root admin 11B Mar 6 2020 /tmp -> private/tmp
The text was updated successfully, but these errors were encountered: