diff --git a/include/uv/unix.h b/include/uv/unix.h index a5447ceb..7c972026 100644 --- a/include/uv/unix.h +++ b/include/uv/unix.h @@ -509,6 +509,4 @@ typedef struct { #define UV_FS_O_SEQUENTIAL 0 #define UV_FS_O_TEMPORARY 0 -#define UV_SPAWN_BUFFER_SIZE (64 * 1024) - #endif /* UV_UNIX_H */ diff --git a/src/unix/process.c b/src/unix/process.c index a2563f06..beedb128 100644 --- a/src/unix/process.c +++ b/src/unix/process.c @@ -205,7 +205,7 @@ static int uv__process_init_stdio(uv_stdio_container_t* container, int fds[2]) { #ifdef __APPLE__ if(ret == 0) { - int size = UV_SPAWN_BUFFER_SIZE; + int size = 64 * 1024; int options[] = {SO_RCVBUF, SO_SNDBUF}; for (int i = 0; i < 2; i++) { diff --git a/test/test-spawn.c b/test/test-spawn.c index ab810c67..da459556 100644 --- a/test/test-spawn.c +++ b/test/test-spawn.c @@ -608,15 +608,16 @@ TEST_IMPL(spawn_stdin) { int recv_fd; int send_buf; int send_fd; + int size = 64 * 1024; socklen_t optlen = sizeof(int); ASSERT_OK(uv_fileno((uv_handle_t*) options.stdio[0].data.stream, &recv_fd)); ASSERT_OK(getsockopt(recv_fd, SOL_SOCKET, SO_RCVBUF, &recv_buf, &optlen)); - ASSERT_EQ(recv_buf, UV_SPAWN_BUFFER_SIZE); + ASSERT_EQ(recv_buf, size); ASSERT_OK(uv_fileno((uv_handle_t*) options.stdio[1].data.stream, &send_fd)); ASSERT_OK(getsockopt(send_fd, SOL_SOCKET, SO_SNDBUF, &send_buf, &optlen)); - ASSERT_EQ(send_buf, UV_SPAWN_BUFFER_SIZE); + ASSERT_EQ(send_buf, size); #endif buf.base = buffer;