Kaynağa Gözat

fix(sudoloop): stop update sudo from taking extra flags, fixes #1427

jguer 4 yıl önce
ebeveyn
işleme
b7f730a59a
1 değiştirilmiş dosya ile 1 ekleme ve 3 silme
  1. 1 3
      exec.go

+ 1 - 3
exec.go

@@ -28,9 +28,7 @@ func sudoLoop() {
 
 func updateSudo() {
 	for {
-		mSudoFlags := strings.Fields(config.SudoFlags)
-		mSudoFlags = append([]string{"-v"}, mSudoFlags...)
-		err := config.Runtime.CmdRunner.Show(exec.Command(config.SudoBin, mSudoFlags...))
+		err := config.Runtime.CmdRunner.Show(exec.Command(config.SudoBin, "-v"))
 		if err != nil {
 			fmt.Fprintln(os.Stderr, err)
 		} else {