]> Cypherpunks repositories - gostls13.git/commit
os: return a *PathError from Readdirnames and Readdir on POSIX platforms
authorBryan C. Mills <bcmills@google.com>
Wed, 13 May 2020 18:59:29 +0000 (14:59 -0400)
committerBryan C. Mills <bcmills@google.com>
Tue, 25 Aug 2020 04:39:40 +0000 (04:39 +0000)
commitb3d9cf7a07518020c6ec5032474aafef9345cdd5
treea7ca759dbce7213fb26fee728e91f9f8714d75ea
parentc78d215ce38288afe382d38af11b6692ce44c368
os: return a *PathError from Readdirnames and Readdir on POSIX platforms

Previously, Readdirnames returned a *PathError on Windows and Plan 9,
but a *SyscallError on POSIX systems.

In contrast, similar methods (such as Stat) return a *PathError on all platforms.

Fixes #38923

Change-Id: I26395905b1e723933f07b792c7aeee7c335949cd
Reviewed-on: https://go-review.googlesource.com/c/go/+/233917
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/os/dir_darwin.go
src/os/dir_unix.go
src/os/os_test.go