|
|
Message-ID: <CAJgzZorndMW7zCOHiOCXQ8Jt86bRZ3_dhF40iJmerS=WXNfASw@mail.gmail.com> Date: Tue, 7 Jul 2026 15:45:34 -0400 From: enh <enh@...gle.com> To: libc-coord@...ts.openwall.com Subject: Re: pthread_create and translation of errors to EAGAIN yeah, bionic does the same thing (for the same "posix told me to" reason), and now you've made me think about it, it does seem unhelpful at best (given that we're on a linux system with overcommit)... "i'll change mine if you change yours"? On Mon, Jun 15, 2026 at 4:42 AM Florian Weimer <fweimer@...hat.com> wrote: > > We currently translate ENOMEM errors to EAGAIN because of the POSIX > requirement to use EAGAIN if the “system lacked the necessary resources > to create another thread”. However, EAGAIN may be a spurious error due > to incorrect resource accounting in the kernel, while ENOMEM most likely > is not. Some applications and frameworks wrap pthread_create in loops > that retry (for a while/a number of times) if pthread_create fails with > EAGAIN. Due to our error code translation, these retries happen for > (original) ENOMEM errors, too, where they are pointless. > > Should we avoid the error code translation? > > Thanks, > Florian >
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.