Skip to content
Commit fc2e634e authored by Aleksa Sarai's avatar Aleksa Sarai Committed by Shuah Khan
Browse files

kselftest: save-and-restore errno to allow for %m formatting



Previously, using "%m" in a ksft_* format string can result in strange
output because the errno value wasn't saved before calling other libc
functions. The solution is to simply save and restore the errno before
we format the user-supplied format string.

Signed-off-by: default avatarAleksa Sarai <cyphar@cyphar.com>
Signed-off-by: default avatarShuah Khan <skhan@linuxfoundation.org>
parent 527d37e9
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment