|
From: | Paul Eggert |
Subject: | bug#49209: coreutils: stack out-of-bounds write in tail --follow |
Date: | Thu, 24 Jun 2021 08:50:16 -0700 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 |
On 6/24/21 7:50 AM, Pádraig Brady wrote:
We should be able to inotify_init() earlier in the process to avoid this issue.
inotify_init can return 1025 even if called first thing, so we also need to dup2 the result of early inotify_init down to 3 (or whatever), or at least to check that it's less than 1024. Choosing 3 is a tricky business, since it's not clear what fds the C library actually needs.
[Prev in Thread] | Current Thread | [Next in Thread] |