Merge pull request #8 from TNkemdilim/hotfix/handle-linux-compilation
Fix(Linux): Include 'CreationFailed' Error In Conditional Compilation
This commit is contained in:
+4
-3
@@ -7,14 +7,15 @@ use std::fmt;
|
|||||||
/// Error that might occur when interacting managing wireless hotspot.
|
/// Error that might occur when interacting managing wireless hotspot.
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
pub enum WifiHotspotError {
|
pub enum WifiHotspotError {
|
||||||
/// Failed to ceate wireless hotspot.
|
/// Failed to ceate wireless hotspot.s
|
||||||
#[cfg(target_os = "linux")]
|
#[cfg(any(target_os = "windows", target_os = "linux"))]
|
||||||
#[cfg(target_os = "windows")]
|
|
||||||
CreationFailed,
|
CreationFailed,
|
||||||
|
|
||||||
/// Failed to stop wireless hotspot service. Try turning off
|
/// Failed to stop wireless hotspot service. Try turning off
|
||||||
/// the wireless interface via ```wifi.turn_off()```.
|
/// the wireless interface via ```wifi.turn_off()```.
|
||||||
#[cfg(target_os = "linux")]
|
#[cfg(target_os = "linux")]
|
||||||
FailedToStop(std::io::Error),
|
FailedToStop(std::io::Error),
|
||||||
|
|
||||||
/// A wireless interface error occurred.
|
/// A wireless interface error occurred.
|
||||||
Other { kind: WifiError },
|
Other { kind: WifiError },
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -26,8 +26,9 @@ pub enum HotspotBand {
|
|||||||
Bg,
|
Bg,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Clone, Copy)]
|
|
||||||
/// Channel to broadcast wireless hotspot on.
|
/// Channel to broadcast wireless hotspot on.
|
||||||
|
#[allow(dead_code)]
|
||||||
|
#[derive(Debug, Clone, Copy)]
|
||||||
pub enum Channel {
|
pub enum Channel {
|
||||||
/// Channel 1
|
/// Channel 1
|
||||||
One = 1,
|
One = 1,
|
||||||
|
|||||||
Reference in New Issue
Block a user