0002-unix-uxpoll-need-_XOPEN_SOURCE.patch 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. From c1b9d07d39e33e40d2ad04be176367cf48271cfd Mon Sep 17 00:00:00 2001
  2. From: Baruch Siach <baruch@tkos.co.il>
  3. Date: Tue, 26 Mar 2019 20:00:45 +0200
  4. Subject: [PATCH] unix/uxpoll: need _XOPEN_SOURCE
  5. MIME-Version: 1.0
  6. Content-Type: text/plain; charset=UTF-8
  7. Content-Transfer-Encoding: 8bit
  8. The code needs _XOPEN_SOURCE for some poll() flags.
  9. Fix this build failure with uClibc:
  10. ./../unix/uxpoll.c: In function ‘pollwrap_add_fd_rwx’:
  11. ./../unix/uxpoll.c:75:32: error: ‘POLLRDNORM’ undeclared (first use in this function); did you mean ‘POLLNVAL’?
  12. #define SELECT_R_IN (POLLIN | POLLRDNORM | POLLRDBAND)
  13. ^
  14. ./../unix/uxpoll.c:87:19: note: in expansion of macro ‘SELECT_R_IN’
  15. events |= SELECT_R_IN;
  16. ^~~~~~~~~~~
  17. Signed-off-by: Baruch Siach <baruch@tkos.co.il>
  18. ---
  19. Upstream status: issue reported to upstream developers
  20. unix/uxpoll.c | 1 +
  21. 1 file changed, 1 insertion(+)
  22. diff --git a/unix/uxpoll.c b/unix/uxpoll.c
  23. index bbc5490d125d..6fe6ac7ba0c1 100644
  24. --- a/unix/uxpoll.c
  25. +++ b/unix/uxpoll.c
  26. @@ -1,3 +1,4 @@
  27. +#define _XOPEN_SOURCE
  28. #include <poll.h>
  29. #include "putty.h"
  30. --
  31. 2.20.1