]> Cypherpunks repositories - gostls13.git/commit
os: avoid panic in Root when symlink references the root
authorDamien Neil <dneil@google.com>
Thu, 27 Mar 2025 23:22:38 +0000 (16:22 -0700)
committerDamien Neil <dneil@google.com>
Fri, 28 Mar 2025 05:25:37 +0000 (22:25 -0700)
commitcfc784a152ebbc4fc0b8bf13c02e0f6eb9c980bd
tree704a9f64706146db3440e73073eec1cc59da5faf
parentb17a99d6fca7f33bb821d450ebe67d6d4b3ea289
os: avoid panic in Root when symlink references the root

We would panic when opening a symlink ending in ..,
where the symlink references the root itself.

Fixes #73081

Change-Id: I7dc3f041ca79df7942feec58c197fde6881ecae5
Reviewed-on: https://go-review.googlesource.com/c/go/+/661416
Reviewed-by: Alan Donovan <adonovan@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
src/os/root_openat.go
src/os/root_test.go