From 0ba5230d078530fe4daa79b6269675a581fda7f5 Mon Sep 17 00:00:00 2001 From: FxQnLr Date: Thu, 11 Apr 2024 15:42:55 +0200 Subject: revert removal of `create_buffer` --- src/routes/start.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/routes') diff --git a/src/routes/start.rs b/src/routes/start.rs index ae2b384..bbc6ab8 100644 --- a/src/routes/start.rs +++ b/src/routes/start.rs @@ -1,7 +1,7 @@ use crate::storage::Device; use crate::error::Error; use crate::services::ping::Value as PingValue; -use crate::wol::send_packet; +use crate::wol::{create_buffer, send_packet}; use axum::extract::{Path, State}; use axum::Json; use serde::{Deserialize, Serialize}; @@ -61,10 +61,10 @@ fn send_wol( let bind_addr = "0.0.0.0:0"; - let _ = send_packet( + send_packet( bind_addr, &device.broadcast_addr.to_string(), - &device.mac.bytes() + &create_buffer(&device.mac.to_string())? )?; let dev_id = device.id.clone(); let uuid = if let Some(pl) = payload { -- cgit v1.2.3