From 61fb8d8c6719205c686550e591db22aa97b4db4c Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Mon, 12 Nov 2018 21:45:08 +0100 Subject: patch 8.1.0526: running out of signal stack in RealWaitForChar Problem: Running out of signal stack in RealWaitForChar. (Vladimir Marek) Solution: Make the fd_set variables static. --- src/os_unix.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/os_unix.c') diff --git a/src/os_unix.c b/src/os_unix.c index 94e1a5357..4d902d939 100644 --- a/src/os_unix.c +++ b/src/os_unix.c @@ -6194,7 +6194,9 @@ RealWaitForChar(int fd, long msec, int *check_for_gpm UNUSED, int *interrupted) struct timeval tv; struct timeval *tvp; - fd_set rfds, wfds, efds; + // These are static because they can take 8 Kbyte each and cause the + // signal stack to run out with -O3. + static fd_set rfds, wfds, efds; int maxfd; long towait = msec; -- cgit v1.2.1