From patchwork Fri Nov 10 03:07:14 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luke Shumaker X-Patchwork-Id: 24189 Received: (qmail 51623 invoked by alias); 10 Nov 2017 03:07:20 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 51614 invoked by uid 89); 10 Nov 2017 03:07:20 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RP_MATCHES_RCVD, SPF_HELO_PASS, SPF_PASS autolearn=ham version=3.3.2 spammy=Hx-languages-length:1335 X-HELO: mav.lukeshu.com From: Luke Shumaker To: libc-alpha@sourceware.org Cc: Adhemerval Zanella Subject: [PATCH] linux epoll_wait: Include Date: Thu, 9 Nov 2017 22:07:14 -0500 Message-Id: <20171110030714.22366-1-lukeshu@lukeshu.com> The epoll_wait wrapper uses the raw syscall if __NR_epoll_wait is defined, and falls back to calling epoll_pwait(..., NULL) if it isn't defined. However, it didn't include the appropriate headers for __NR_epoll_wait to be defined, so it was *always* falling back to calling epoll_pwait! This mistake was introduced in b62c3815912bc679a966134affdedd3f35ae8621, when epoll_wait changed from being in syscalls.list to always having a C wrapper. Reviewed-by: Adhemerval Zanella --- ChangeLog | 4 ++++ sysdeps/unix/sysv/linux/epoll_wait.c | 2 ++ 2 files changed, 6 insertions(+) diff --git a/ChangeLog b/ChangeLog index 475945bc32..807a826335 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2017-11-09 Luke Shumaker + + * sysdeps/unix/sysv/linux/epoll_wait.c: Include . + 2017-11-09 H.J. Lu * include/setjmp.h [!_ISOMAC]: Include and diff --git a/sysdeps/unix/sysv/linux/epoll_wait.c b/sysdeps/unix/sysv/linux/epoll_wait.c index eb6e6d3ace..b324ff832a 100644 --- a/sysdeps/unix/sysv/linux/epoll_wait.c +++ b/sysdeps/unix/sysv/linux/epoll_wait.c @@ -21,6 +21,8 @@ #include #include +#include + int epoll_wait (int epfd, struct epoll_event *events, int maxevents, int timeout) {