diff --git a/src/bin/julialauncher.rs b/src/bin/julialauncher.rs index 759f7b57..6a63b8c5 100644 --- a/src/bin/julialauncher.rs +++ b/src/bin/julialauncher.rs @@ -5,8 +5,6 @@ use itertools::Itertools; use juliaup::config_file::{load_config_db, JuliaupConfig, JuliaupConfigChannel}; use juliaup::global_paths::get_paths; use juliaup::jsonstructs_versionsdb::JuliaupVersionDB; -#[cfg(not(windows))] -use juliaup::utils::is_valid_julia_path; use juliaup::versions_file::load_versions_db; #[cfg(not(windows))] use nix::{ @@ -398,19 +396,15 @@ fn run_app() -> Result { } // replace the current process - if is_valid_julia_path(&julia_path) { - std::process::Command::new(julia_path) - .args(&new_args) - .exec(); - } else { - panic!( - "Could not launch Julia. Verify that there is a valid Julia binary at \"{}\".", - julia_path.to_string_lossy() - ); - } - - // this is never reached - Ok(0) + std::process::Command::new(&julia_path) + .args(&new_args) + .exec(); + + // this is only ever reached if launching Julia fails + panic!( + "Could not launch Julia. Verify that there is a valid Julia binary at \"{}\".", + julia_path.to_string_lossy() + ) } Ok(ForkResult::Child) => { // double-fork to prevent zombies