1
0
mirror of https://github.com/danog/libdvb.git synced 2024-11-26 20:04:39 +01:00
This commit is contained in:
Andrey Dyldin 2021-03-08 16:57:12 +02:00
parent 1af4957fa6
commit 54fee799a7
3 changed files with 4 additions and 8 deletions

View File

@ -7,9 +7,6 @@ pub mod sys;
use {
std::{
path::{
Path,
},
fs::{
File,
OpenOptions,
@ -102,8 +99,8 @@ impl CaDevice {
.read(true)
.write(true)
.custom_flags(::nix::libc::O_NONBLOCK)
.open(path)
.with_context(|| format!("CA: failed to open device {}", path.display()))?;
.open(&path)
.with_context(|| format!("CA: failed to open device {}", &path))?;
let mut ca = CaDevice {
adapter,

View File

@ -21,7 +21,6 @@ use {
RawFd,
},
},
path::Path,
},
anyhow::{
@ -177,7 +176,7 @@ impl FeDevice {
.write(!readonly)
.custom_flags(::nix::libc::O_NONBLOCK)
.open(&path)
.context("FE: open")?;
.with_context(|| format!("FE: failed to open device {}", &path))?;
let mut fe = FeDevice {
adapter,

View File

@ -64,7 +64,7 @@ impl NetDevice {
.write(true)
.custom_flags(::nix::libc::O_NONBLOCK)
.open(&path)
.context("NET: open")?;
.with_context(|| format!("NET: failed to open device {}", &path))?;
let net = NetDevice {
adapter,