Skip to content

Commit

Permalink
0.95.5 - Fix Win32 compile
Browse files Browse the repository at this point in the history
  • Loading branch information
rnd-ash committed Dec 24, 2023
1 parent 6784e95 commit aa06b06
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "ecu_diagnostics"
version = "0.95.4"
version = "0.95.5"
authors = ["Ashcon Mohseninia <[email protected]>"]
edition = "2021"
description = "A rust crate for ECU diagnostic servers and communication APIs"
Expand Down
6 changes: 3 additions & 3 deletions src/channel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use std::{
sync::{mpsc, Arc, Mutex, PoisonError},
};

#[cfg(feature="socketcan")]
#[cfg(all(feature="socketcan", target_os="linux"))]
use socketcan::{EmbeddedFrame, Id, ExtendedId, StandardId, CanDataFrame};

use crate::hardware::HardwareError;
Expand Down Expand Up @@ -448,7 +448,7 @@ impl Packet for CanFrame {
}
}

#[cfg(feature="socketcan")]
#[cfg(all(feature="socketcan", target_os="linux"))]
impl From<CanDataFrame> for CanFrame {
fn from(value: CanDataFrame) -> Self {
let (id, ext) = match value.id() {
Expand All @@ -459,7 +459,7 @@ impl From<CanDataFrame> for CanFrame {
}
}

#[cfg(feature="socketcan")]
#[cfg(all(feature="socketcan", target_os="linux"))]
impl Into<CanDataFrame> for CanFrame {
fn into(self) -> CanDataFrame {
let id = match self.ext {
Expand Down
2 changes: 1 addition & 1 deletion src/hardware/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ pub mod passthru; // Not finished at all yet, hide from the crate
#[cfg(feature = "passthru")]
use std::sync::Arc;

#[cfg(all(feature = "socketcan", unix))]
#[cfg(all(feature="socketcan", target_os="linux"))]
pub mod socketcan;

use crate::channel::{CanChannel, IsoTPChannel};
Expand Down

0 comments on commit aa06b06

Please sign in to comment.