go/src/path/filepath
Damien Neil 6e43407931 path/filepath: don't drop .. elements when cleaning invalid Windows paths
Fix a bug where Clean could improperly drop .. elements from a
path on Windows, when the path contains elements containing a ':'.

For example, Clean("a/../b:/../../c") now correctly returns "..\c"
rather than "c".

Fixes #61866

Change-Id: I97b0238953c183b2ce19ca89c14f26700008ea72
Reviewed-on: https://go-review.googlesource.com/c/go/+/517216
Run-TryBot: Damien Neil <dneil@google.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Quim Muntal <quimmuntal@gmail.com>
2023-08-08 21:48:12 +00:00
..
example_test.go
example_unix_test.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
example_unix_walk_test.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
export_test.go
export_windows_test.go
match.go path/filepath: fix stack exhaustion in Glob 2022-07-12 15:06:01 +00:00
match_test.go path/filepath: fix stack exhaustion in Glob 2022-07-12 15:06:01 +00:00
path.go path/filepath: don't drop .. elements when cleaning invalid Windows paths 2023-08-08 21:48:12 +00:00
path_plan9.go path/filepath: add IsLocal 2022-11-16 23:17:58 +00:00
path_test.go path/filepath: don't drop .. elements when cleaning invalid Windows paths 2023-08-08 21:48:12 +00:00
path_unix.go all: add wasip1 support 2023-04-11 20:56:32 +00:00
path_windows.go path/filepath: make Join("c:", "/a") return "c:/a" again 2022-12-02 19:48:47 +00:00
path_windows_test.go path/filepath: do not Clean("a/../c:/b") into c:\b on Windows 2023-02-14 16:51:16 +00:00
symlink.go path/filepath: fix evaluation of symlinks to paths under /tmp on macOS 2023-01-20 22:42:39 +00:00
symlink_plan9.go path/filepath: simplify EvalSymlinks for plan9 2022-05-09 14:44:54 +00:00
symlink_unix.go all: add missing copyright header 2022-11-09 14:05:53 +00:00
symlink_windows.go path/filepath: remove extra Clean call in EvalSymlinks on Windows 2023-01-24 07:42:17 +00:00