[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAACtx1b_v3nbv8EkAQ1f7ee=yt3ECm_a6kb1KNdBPZ5F20ndFw@mail.gmail.com>
Date: Sun, 29 Aug 2021 15:57:06 -0400
From: Andrew Wock <ajwock@...il.com>
To: linux-man@...r.kernel.org, alx.manpages@...il.com,
mtk.manpages@...il.com
Cc: christian@...uner.io, linux-kernel@...r.kernel.org
Subject: [patch] clone.2: Add EACCES with CLONE_INTO_CGROUP + clone3 to ERRORS
Resending because it's my first time mailing the lkml and I used html.
Reattempting w/ gmail's plaintext mode. I apologise if this is
reaching you twice.
I noticed that clone3 can send the EACCES errno after I wrote a
program that used clone3 with the CLONE_INTO_CGROUP flag. To me, it's
important to know what kind of failure occurred if the clone3 fails,
so I was glad that a unique errno is set for this case, but it wasn't
documented on the clone man page.
I've attached a patch and a test program.
Test program is attached as clone3_doc.c. Create
/sys/fs/cgroup/not-allowed as root, then run the program. It should
set errno to EACCES.
Thanks,
Andrew Wock
View attachment "clone3_doc.c" of type "text/plain" (1276 bytes)
Download attachment "clone.2.diff" of type "application/octet-stream" (592 bytes)
Powered by blists - more mailing lists