mirror of
https://github.com/systemd/systemd.git
synced 2026-08-09 01:20:53 +00:00
errno: add new ERRNO_IS_NOT_SUPPORTED() helper
This commit is contained in:
@@ -86,3 +86,11 @@ static inline bool ERRNO_IS_RESOURCE(int r) {
|
||||
ENFILE,
|
||||
ENOMEM);
|
||||
}
|
||||
|
||||
/* Three different errors for "operation/system call/ioctl not supported" */
|
||||
static inline bool ERRNO_IS_NOT_SUPPORTED(int r) {
|
||||
return IN_SET(abs(r),
|
||||
EOPNOTSUPP,
|
||||
ENOTTY,
|
||||
ENOSYS);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user