From 908762073fb9ad3e9c172b52133d48d818c1e1e7 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 23 Mar 2026 13:18:49 -0700 Subject: [PATCH] Fix ffmpeg permission denied on Linux The bundled ffmpeg in the sidecar extract dir lacked execute permissions. Now sets chmod 755 on Unix when find_ffmpeg locates the bundled binary. Co-Authored-By: Claude Opus 4.6 --- src-tauri/src/commands/media.rs | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src-tauri/src/commands/media.rs b/src-tauri/src/commands/media.rs index c1f31f1..fac99b2 100644 --- a/src-tauri/src/commands/media.rs +++ b/src-tauri/src/commands/media.rs @@ -99,6 +99,16 @@ fn find_ffmpeg() -> Option { }; let ffmpeg_path = sidecar_dir.join(ffmpeg_name); if ffmpeg_path.exists() { + // Ensure execute permission on Unix + #[cfg(unix)] + { + use std::os::unix::fs::PermissionsExt; + if let Ok(meta) = std::fs::metadata(&ffmpeg_path) { + let mut perms = meta.permissions(); + perms.set_mode(0o755); + let _ = std::fs::set_permissions(&ffmpeg_path, perms); + } + } return Some(ffmpeg_path.to_string_lossy().to_string()); } }