Skip to content

Commit bd3bdcd

Browse files
committed
Add ENOTSUP to Linux and Android
While ENOTSUP is defined as equal to EOPNOTSUPP on these platforms, exposing the ENOTSUP symbol (as libc does) allows for writing portable code that may want to reference this error code.
1 parent 2d0d360 commit bd3bdcd

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,10 @@ This project adheres to [Semantic Versioning](http://semver.org/).
77
### Added
88
- Add IP_RECVIF & IP_RECVDSTADDR. Enable IP_PKTINFO and IP6_PKTINFO on netbsd/openbsd.
99
([#1002](https://github.com/nix-rust/nix/pull/1002))
10-
1110
- Added `inotify_init1`, `inotify_add_watch` and `inotify_rm_watch` wrappers for
1211
Android and Linux. ([#1016](https://github.com/nix-rust/nix/pull/1016))
12+
- Added ENOTSUP errno support for Linux and Android.
13+
([#969](https://github.com/nix-rust/nix/pull/969))
1314

1415
### Changed
1516
- `PollFd` event flags renamed to `PollFlags` ([#1024](https://github.com/nix-rust/nix/pull/1024/))

src/errno.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -675,6 +675,7 @@ mod consts {
675675

676676
pub const EWOULDBLOCK: Errno = Errno::EAGAIN;
677677
pub const EDEADLOCK: Errno = Errno::EDEADLK;
678+
pub const ENOTSUP: Errno = Errno::ENOTSUP;
678679

679680
pub fn from_i32(e: i32) -> Errno {
680681
use self::Errno::*;

0 commit comments

Comments
 (0)