Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 18f661bc authored by Stephen Wilson's avatar Stephen Wilson Committed by Al Viro
Browse files

proc: hold cred_guard_mutex in check_mem_permission()



Avoid a potential race when task exec's and we get a new ->mm but check against
the old credentials in ptrace_may_access().

Holding of the mutex is implemented by factoring out the body of the code into a
helper function __check_mem_permission().  Performing this factorization now
simplifies upcoming changes and minimizes churn in the diff's.

Signed-off-by: default avatarStephen Wilson <wilsons@start.ca>
Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
parent 26947f8c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment