Skip to content
Commit 9ec31e57 authored by Sergey Bugaev's avatar Sergey Bugaev Committed by Samuel Thibault
Browse files

hurd: Use __hurd_fail () instead of assigning errno



The __hurd_fail () inline function is the dedicated, idiomatic way of
reporting errors in the Hurd part of glibc. Not only is it more concise
than '{ errno = err; return -1; }', it is since commit
6639cc10
"hurd: Mark error functions as __COLD" marked with the cold attribute,
telling the compiler that this codepath is unlikely to be executed.

In one case, use __hurd_dfail () over the plain __hurd_fail ().

Signed-off-by: default avatarSergey Bugaev <bugaevc@gmail.com>
Message-Id: <20230520115531.3911877-1-bugaevc@gmail.com>
parent 36cc908e
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