fortify-headers: fix inconsistent time_t version of ppoll
authorGeorgi Valkov <gvalkov@gmail.com>
Wed, 10 May 2023 00:02:29 +0000 (03:02 +0300)
committerHauke Mehrtens <hauke@hauke-m.de>
Fri, 12 May 2023 10:16:11 +0000 (12:16 +0200)
commitddfe5678a448ac8875e94f2fb4ddca67416fa14a
tree5a54bed0a3962372a8407cbe8b68787ee6abd104
parent8d2ab0fac666b9d2f39f517594b414466ff85818
fortify-headers: fix inconsistent time_t version of ppoll

Bug:
fortify/poll.h includes poll.h, which redirects ppoll to __ppoll_time64
if the _REDIR_TIME64 macro is 1. Then fortify/poll.h will #undef ppoll
and use the 32 bit version.

Fix: we should not do this when _REDIR_TIME64 is 1.

[1] https://forum.openwrt.org/t/idle-cpu-usage-of-usbmuxd/140331/15
[2] https://github.com/openwrt/openwrt/issues/12574

Signed-off-by: Georgi Valkov <gvalkov@gmail.com>
toolchain/fortify-headers/Makefile
toolchain/fortify-headers/patches/001-__ppoll_time64.patch [new file with mode: 0644]