From: Jérémie Galarneau Date: Fri, 16 Oct 2020 18:43:39 +0000 (-0400) Subject: Fix: common: poll: compat_poll_wait never finishes X-Git-Tag: v2.11.6~7 X-Git-Url: https://git.lttng.org/?a=commitdiff_plain;h=13c4d8aba5eca5f0d70a42661731d2de6bdc02a4;hp=13c4d8aba5eca5f0d70a42661731d2de6bdc02a4;p=lttng-tools.git Fix: common: poll: compat_poll_wait never finishes compat_poll_wait hangs when poll returns an array of file descriptors of the form: [ Inactive Active ] The logic to find the first idle pollfd entry is bogus and actually skips the first idle entry. This causes the follow-up loop to never conclude. The pollfd array defragmentation logic is re-written in a simpler style to handle those cases appropriately. Signed-off-by: Jérémie Galarneau Change-Id: I8669a870df1ec1160f05e35e83671917bb80d6f9 ---