]> Cypherpunks repositories - gostls13.git/commit
runtime,internal/syscall/windows: remove long path support check
authorqmuntal <quimmuntal@gmail.com>
Thu, 19 Oct 2023 16:06:27 +0000 (18:06 +0200)
committerQuim Muntal <quimmuntal@gmail.com>
Wed, 7 Feb 2024 20:54:38 +0000 (20:54 +0000)
commitc0984005487b293b4bb2f92e8cd9b58422f7831e
tree4a7ca58fc67fda1bf8b00ae85c72949e031fa22f
parent28b8851671a0254ed0e46ce8dbec43ebe73e7132
runtime,internal/syscall/windows: remove long path support check

The runtime currently enables long path support process-wide by updating
the process environment block (PEB). It then tries to create a file
using a long path to check if the PEB update made any difference.

There hasn't been any report that the PEB update was not effective,
and the check itself is quite tricky, so it's time to remove it.

While here, linkname `runtime.canUseLongPaths` to a variable in
internal/syscall/windows instead of the os package so it is easier to
consume from other packages.

Change-Id: I549380b7f2c242dc4db20d5be603840282de69b9
Reviewed-on: https://go-review.googlesource.com/c/go/+/536495
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Alex Brainman <alex.brainman@gmail.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
Reviewed-by: David Chase <drchase@google.com>
src/internal/syscall/windows/syscall_windows.go
src/os/export_windows_test.go
src/os/path_windows.go
src/os/path_windows_test.go
src/runtime/os_windows.go