From e1d96a874e01c5aa930a2cd6c870c829eabd6663 Mon Sep 17 00:00:00 2001 From: Soner Tari Date: Sat, 3 Nov 2018 20:23:54 +0300 Subject: [PATCH] Disable getdtablecount() on osx, temporarily --- pxyconn.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/pxyconn.c b/pxyconn.c index 59becc0..1c018ad 100644 --- a/pxyconn.c +++ b/pxyconn.c @@ -776,7 +776,11 @@ pxy_log_dbg_disconnect_child(pxy_conn_child_ctx_t *ctx) } } -#if defined(__linux__) || defined(__APPLE__) +#ifdef __APPLE__ +#define getdtablecount() 0 +#endif /* __APPLE__ */ + +#ifdef __linux__ /* * Copied from: * https://github.com/tmux/tmux/blob/master/compat/getdtablecount.c @@ -811,7 +815,7 @@ getdtablecount() globfree(&g); return n; } -#endif /* defined(__linux__) || defined(__APPLE__) */ +#endif /* __linux__ */ unsigned char * pxy_malloc_packet(size_t sz, pxy_conn_ctx_t *ctx)