From 8381ed280e0ddd560c8b544b59eca6c8c7334b8e Mon Sep 17 00:00:00 2001 From: Mitchell R Date: Tue, 26 May 2026 15:03:29 +0200 Subject: [PATCH] fix: md5 crate v0.7 API (compute not Digest) + clone default_layout_id Co-Authored-By: Claude Opus 4.6 (1M context) --- kiosk/src/bundle.rs | 2 +- kiosk/src/onvif_events.rs | 7 ++----- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/kiosk/src/bundle.rs b/kiosk/src/bundle.rs index 35053b9..55a6eea 100644 --- a/kiosk/src/bundle.rs +++ b/kiosk/src/bundle.rs @@ -69,7 +69,7 @@ impl KioskBundle { height_px: d.height_px, idle_timeout_seconds: d.idle_timeout_seconds, sleep_timeout_seconds: d.sleep_timeout_seconds, - default_layout_id: d.default_layout_id, + default_layout_id: d.default_layout_id.clone(), layouts: self.layouts.clone(), }]; } diff --git a/kiosk/src/onvif_events.rs b/kiosk/src/onvif_events.rs index f8c2a46..a49ee98 100644 --- a/kiosk/src/onvif_events.rs +++ b/kiosk/src/onvif_events.rs @@ -694,11 +694,8 @@ fn extract_digest_field(header: &str, field: &str) -> Option { } fn md5_hex(input: &str) -> String { - use md5::{Digest, Md5}; - let mut hasher = Md5::new(); - hasher.update(input.as_bytes()); - let result = hasher.finalize(); - hex_lower_bytes(&result) + let digest = md5::compute(input.as_bytes()); + hex_lower_bytes(&digest.0) } fn hex_lower_bytes(bytes: &[u8]) -> String {