X-Git-Url: https://scm.lunaixsky.com/lunaix-os.git/blobdiff_plain/642855f81fd03b9fd6540ac99c665b57b4b38cc8..836d44ecb7a2c37427f6baf8b25e872e9e943d5b:/lunaix-os/includes/lunaix/syscall_utils.h diff --git a/lunaix-os/includes/lunaix/syscall_utils.h b/lunaix-os/includes/lunaix/syscall_utils.h index fcc7dc3..d29056d 100644 --- a/lunaix-os/includes/lunaix/syscall_utils.h +++ b/lunaix-os/includes/lunaix/syscall_utils.h @@ -3,8 +3,10 @@ #include #include +#include -#define DO_STATUS(errno) SYSCALL_ESTATUS(__current->k_status = errno) -#define DO_STATUS_OR_RETURN(errno) ({ errno < 0 ? DO_STATUS(errno) : errno; }) +#define DO_STATUS(errno) SYSCALL_ESTATUS(syscall_result(errno)) +#define DO_STATUS_OR_RETURN(errno) \ + ({ errno < 0 ? DO_STATUS(errno) : errno; }) #endif /* __LUNAIX_SYSCALL_UTILS_H */