Skip to content

Commit d8d60c9

Browse files
committed
Update nix to 0.31.3, spidev to 0.7.1
1 parent 932bfdd commit d8d60c9

3 files changed

Lines changed: 6 additions & 4 deletions

File tree

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
1111

1212
- MSRV is now 1.85.0.
1313
- Set `resolver = "3"`, which implies `resolver.incompatible-rust-versions = "fallback"`
14+
- Updated to `nix` `0.31.3`
15+
- Updated to `spidev` `0.7.1`
1416

1517
### Added
1618

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ sysfs_gpio = { version = "0.6.1", optional = true }
3333
i2cdev = { version = "0.6.0", optional = true }
3434
nb = "1"
3535
serialport = { version = "4.2.0", default-features = false, optional = true }
36-
spidev = { version = "0.6.1", optional = true }
37-
nix = { version = "0.27.1", optional = true }
36+
spidev = { version = "0.7.1", optional = true }
37+
nix = { version = "0.31.3", optional = true }
3838
tokio = { version = "1", default-features = false, optional = true }
3939

4040
[dev-dependencies]

src/i2c.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,9 +138,9 @@ impl embedded_hal::i2c::Error for I2CError {
138138
use nix::errno::Errno::*;
139139

140140
let errno = match &self.err {
141-
i2cdev::linux::LinuxI2CError::Errno(e) => nix::Error::from_i32(*e),
141+
i2cdev::linux::LinuxI2CError::Errno(e) => nix::Error::from_raw(*e),
142142
i2cdev::linux::LinuxI2CError::Io(e) => match e.raw_os_error() {
143-
Some(r) => nix::Error::from_i32(r),
143+
Some(r) => nix::Error::from_raw(r),
144144
None => return ErrorKind::Other,
145145
},
146146
};

0 commit comments

Comments
 (0)