]> Cypherpunks repositories - gostls13.git/commit
os: implement fs.ReadFileFS for DirFS
authorSean Liao <sean@liao.dev>
Sat, 9 Jul 2022 18:08:59 +0000 (19:08 +0100)
committerGopher Robot <gobot@golang.org>
Wed, 24 May 2023 15:04:44 +0000 (15:04 +0000)
commit4042b90001490d3ef7418d1c6ff83aa769213bed
tree4643fb5a8d688a22689fa9f6d3e13b1eb8a43804
parent8c30460b870f3ced089cbc2fdada809a331481e1
os: implement fs.ReadFileFS for DirFS

Use the os.ReadFile implementation to handle
sysfs files not reporting size properly via stat.

Fixes #53761

Change-Id: I6f34515e8a211e3659f4f6c3598fae7ec0c86975
Reviewed-on: https://go-review.googlesource.com/c/go/+/416775
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Bryan Mills <bcmills@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
Reviewed-by: Rob Pike <r@golang.org>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Run-TryBot: Rob Pike <r@golang.org>
Reviewed-by: hopehook <hopehook@golangcn.org>
Run-TryBot: Ian Lance Taylor <iant@google.com>
src/os/file.go
src/os/os_test.go