Skip to content

Commit

Permalink
Expose UV_EUNATCH
Browse files Browse the repository at this point in the history
  • Loading branch information
aantron committed Dec 16, 2023
1 parent 580788b commit 3b2c326
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/c/luv_c_type_descriptions.ml
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ struct
let esrch = constant "UV_ESRCH" int
let etimedout = constant "UV_ETIMEDOUT" int
let etxtbsy = constant "UV_ETXTBSY" int
let eunatch = constant "UV_EUNATCH" int
let exdev = constant "UV_EXDEV" int
let unknown = constant "UV_UNKNOWN" int
let eof = constant "UV_EOF" int
Expand Down
2 changes: 2 additions & 0 deletions src/c/shims.h
Original file line number Diff line number Diff line change
Expand Up @@ -743,4 +743,6 @@
{
return ENOSYS;
}

#define UV_EUNATCH 0x7242424
#endif
2 changes: 2 additions & 0 deletions src/error.ml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ type t = [
| `ESRCH
| `ETIMEDOUT
| `ETXTBSY
| `EUNATCH
| `EXDEV
| `UNKNOWN
| `EOF
Expand Down Expand Up @@ -162,6 +163,7 @@ let to_c = let open C.Types.Error in function
| `ESRCH -> esrch
| `ETIMEDOUT -> etimedout
| `ETXTBSY -> etxtbsy
| `EUNATCH -> eunatch
| `EXDEV -> exdev
| `UNKNOWN -> unknown
| `EOF -> eof
Expand Down
1 change: 1 addition & 0 deletions src/error.mli
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ type t = [
| `ESRCH
| `ETIMEDOUT
| `ETXTBSY
| `EUNATCH
| `EXDEV
| `UNKNOWN
| `EOF
Expand Down
2 changes: 2 additions & 0 deletions test/error.ml
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ let tests = [
t "ESRCH" "no such process" `ESRCH;
t "ETIMEDOUT" "connection timed out" `ETIMEDOUT;
t "ETXTBSY" "text file is busy" `ETXTBSY;
t "EUNATCH" "protocol driver not attached" `EUNATCH;
t "EXDEV" "cross-device link not permitted" `EXDEV;
t "UNKNOWN" "unknown error" `UNKNOWN;
t "EOF" "end of file" `EOF;
Expand Down Expand Up @@ -180,6 +181,7 @@ let tests = [
t "ESRCH" `ESRCH;
t "ETIMEDOUT" `ETIMEDOUT;
t "ETXTBSY" `ETXTBSY;
t "EUNATCH" `EUNATCH;
t "EXDEV" `EXDEV;
t "UNKNOWN" `UNKNOWN;
t "EOF" `EOF;
Expand Down

0 comments on commit 3b2c326

Please sign in to comment.