go/src/internal
Keith Randall 9da6530faa syscall: avoid _getdirentries64 on darwin
Getdirentries is implemented with the __getdirentries64 function
in libSystem.dylib. That function works, but it's on Apple's
can't-be-used-in-an-app-store-application list.

Implement Getdirentries using the underlying fdopendir/readdir_r/closedir.
The simulation isn't faithful, and could be slow, but it should handle
common cases.

Don't use Getdirentries in the stdlib, use fdopendir/readdir_r/closedir
instead (via (*os.File).readdirnames).

Fixes #30933

Update #28984

RELNOTE=yes

Change-Id: Ia6b5d003e5bfe43ba54b1e1d9cfa792cc6511717
Reviewed-on: https://go-review.googlesource.com/c/go/+/168479
Reviewed-by: Emmanuel Odeke <emm.odeke@gmail.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Emmanuel Odeke <emm.odeke@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-04-03 21:27:05 +00:00
..
bytealg internal/bytealg: fix function reference in comments 2019-04-02 05:45:33 +00:00
cpu internal/cpu: change s390x API to match x/sys/cpu 2019-02-28 13:46:45 +00:00
errinternal fmt: make type of fmt.Errorf the same as that of errors.New 2019-03-14 09:45:22 +00:00
fmtsort fmtsort: sort interfaces deterministically 2019-02-28 21:09:49 +00:00
goroot all: use "reports whether" consistently instead of "returns whether" 2018-12-02 15:12:26 +00:00
lazyregexp internal/lazytemplate: add a lazy template wrapper 2019-02-27 23:49:01 +00:00
lazytemplate internal/lazytemplate: add a lazy template wrapper 2019-02-27 23:49:01 +00:00
nettrace net, net/http: don't trace DNS dials 2016-05-14 00:14:25 +00:00
oserror os: make errors.Is work with ErrPermission et al. 2019-03-20 16:02:01 +00:00
poll syscall: avoid _getdirentries64 on darwin 2019-04-03 21:27:05 +00:00
race testing: mark tests and benchmarks failed if a race occurs during execution 2016-11-03 18:19:49 +00:00
reflectlite sort, internal/reflectlite: flesh out reflectlite enough for use by sort 2019-03-27 04:58:23 +00:00
singleflight net: don't let cancelation of a DNS lookup affect another lookup 2018-03-16 13:39:38 +00:00
syscall os: make Readlink work with symlinks with target like \??\Volume{ABCD}\ 2019-03-01 07:44:37 +00:00
testenv internal/testenv: remove SetModVendor 2019-03-08 23:40:24 +00:00
testlog cmd/go: invalidate cached test results if env vars or files change 2017-12-11 19:08:32 +00:00
trace cmd/trace: revert internal/traceparser 2018-11-22 02:59:55 +00:00
xcoff all: fix typos as reported by 'misspell' 2019-02-26 23:02:05 +00:00