direct: fix udev feature name
This commit is contained in:
parent
e7575d08b8
commit
d6e7fb591e
|
@ -67,7 +67,7 @@ use std::{
|
||||||
Arc,
|
Arc,
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
#[cfg(feature = "backend_session_udev")]
|
#[cfg(feature = "backend_udev")]
|
||||||
use udev::Context;
|
use udev::Context;
|
||||||
use wayland_server::calloop::{signals::Signals, LoopHandle, Source};
|
use wayland_server::calloop::{signals::Signals, LoopHandle, Source};
|
||||||
|
|
||||||
|
@ -120,12 +120,12 @@ const TTY_MAJOR: u64 = 4;
|
||||||
#[cfg(not(any(target_os = "linux", target_os = "android")))]
|
#[cfg(not(any(target_os = "linux", target_os = "android")))]
|
||||||
const TTY_MAJOR: u64 = 0;
|
const TTY_MAJOR: u64 = 0;
|
||||||
|
|
||||||
#[cfg(not(feature = "backend_session_udev"))]
|
#[cfg(not(feature = "backend_udev"))]
|
||||||
fn is_tty_device(dev: dev_t, _path: Option<&Path>) -> bool {
|
fn is_tty_device(dev: dev_t, _path: Option<&Path>) -> bool {
|
||||||
major(dev) == TTY_MAJOR
|
major(dev) == TTY_MAJOR
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(feature = "backend_session_udev")]
|
#[cfg(feature = "backend_udev")]
|
||||||
fn is_tty_device(dev: dev_t, path: Option<&Path>) -> bool {
|
fn is_tty_device(dev: dev_t, path: Option<&Path>) -> bool {
|
||||||
match path {
|
match path {
|
||||||
Some(path) => {
|
Some(path) => {
|
||||||
|
|
Loading…
Reference in New Issue