aboutsummaryrefslogtreecommitdiff
path: root/include/u.h
diff options
context:
space:
mode:
authorRuss Cox <rsc@swtch.com>2020-05-17 20:02:07 -0400
committerRuss Cox <rsc@swtch.com>2020-05-17 20:15:41 -0400
commit8cb7308f3a24249ed091c7decf22005c64099783 (patch)
tree6e470755d6e1ed612f1d4b8242eeaa59dca0d727 /include/u.h
parent16f60479e16e3714b376e633c6b902a32e0607ea (diff)
downloadplan9port-8cb7308f3a24249ed091c7decf22005c64099783.tar.gz
plan9port-8cb7308f3a24249ed091c7decf22005c64099783.tar.bz2
plan9port-8cb7308f3a24249ed091c7decf22005c64099783.zip
lib9: use opendir/readdir to read directories
getdirentries(2) has been deprecated on macOS since 10.5 (ten releases ago). Using it requires disabling 64-bit inodes, but that in turn makes binaries incompatible with some dynamic libraries, most notably ASAN. At some point getdirentries(2) will actually be removed. For both these reasons, switch to opendir/readdir. A little clunky since we have to keep the DIR* hidden away to preserve the int fd interfaces, but it lets us remove a bunch of OS-specific code too.
Diffstat (limited to 'include/u.h')
-rw-r--r--include/u.h3
1 files changed, 0 insertions, 3 deletions
diff --git a/include/u.h b/include/u.h
index 10fc7257..297df70a 100644
--- a/include/u.h
+++ b/include/u.h
@@ -39,9 +39,6 @@ extern "C" {
# define _ALL_SOURCE
# undef HAS_SYS_TERMIOS
#endif
-#if defined(__APPLE__)
-# define _DARWIN_NO_64_BIT_INODE /* Snow Leopard */
-#endif
#define _LARGEFILE64_SOURCE 1
#define _FILE_OFFSET_BITS 64