From a3ca64275adf8e4b60e8fc57a4a835fd0f71a1d5 Mon Sep 17 00:00:00 2001 From: Amr Bashir Date: Thu, 16 Nov 2023 01:26:11 +0200 Subject: [PATCH] fix(updater): Use escaped installer path to start the msi updater (#728) * fix(updater): Use escaped installer path to start the msi updater Continuation of #727 * change file * fix build --- .changes/updater-escaped-path.md | 2 +- plugins/updater/src/updater.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.changes/updater-escaped-path.md b/.changes/updater-escaped-path.md index 75661ff4..a4356fc4 100644 --- a/.changes/updater-escaped-path.md +++ b/.changes/updater-escaped-path.md @@ -2,4 +2,4 @@ updater: patch --- -Use escaped installer path to start the nsis updater to prevent crashes if app name contained spaces. +Use escaped installer path to start the nsis/msi updater to prevent crashes if app name contained spaces. diff --git a/plugins/updater/src/updater.rs b/plugins/updater/src/updater.rs index 06dc3bfe..303bbdbe 100644 --- a/plugins/updater/src/updater.rs +++ b/plugins/updater/src/updater.rs @@ -551,7 +551,7 @@ impl Update { "-ArgumentList", ]) .arg("/i,") - .arg(msi_path_arg) + .arg(&msi_path_arg) .arg(format!(", {}, /promptrestart;", msiexec_args.join(", "))) .arg("Start-Process") .arg(current_exe_arg) @@ -565,7 +565,7 @@ impl Update { ); let _ = Command::new(msiexec_path) .arg("/i") - .arg(found_path) + .arg(msi_path_arg) .args(msiexec_args) .arg("/promptrestart") .spawn();