From 1667f42fbf7b2f6efde9ced34044fd8b16647220 Mon Sep 17 00:00:00 2001 From: "Jason A. Donenfeld" Date: Wed, 1 May 2019 10:14:01 +0200 Subject: updater: don't pass full paths to msiexec --- updater/msirunner_windows.go | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'updater') diff --git a/updater/msirunner_windows.go b/updater/msirunner_windows.go index 7a4e9d72..a11ed335 100644 --- a/updater/msirunner_windows.go +++ b/updater/msirunner_windows.go @@ -17,10 +17,9 @@ func runMsi(msiPath string) error { if err != nil { return err } - // BUG: The Go documentation says that its built-in shell quoting isn't good for msiexec.exe. - // See https://github.com/golang/go/issues/15566. But perhaps our limited set of options - // actually works fine? Investigate this! - return exec.Command(path.Join(system32, "msiexec.exe"), "/qb-", "/i", msiPath).Run() + cmd := exec.Command(path.Join(system32, "msiexec.exe"), "/qb-", "/i", path.Base(msiPath)) + cmd.Dir = path.Dir(msiPath) + return cmd.Run() } func msiSaveDirectory() (string, error) { -- cgit v1.2.3-59-g8ed1b