ox icon indicating copy to clipboard operation
ox copied to clipboard

fix to execas.Command

Open zerobyted opened this issue 5 years ago • 0 comments

cm := execas.Command("notepad")
cm.Username = "gola"
cm.Password = "loga"
err := cm.Start()
if err != nil {
    fmt.Println("err", err.Error())
}

panics after start process https://github.com/itchio/ox/blob/32d876f09b55bb103381bf8bf41036f5dadd0172/syscallex/exec_windows.go#L254-L255

attr.Sys == nil because there no update after

https://github.com/itchio/ox/blob/32d876f09b55bb103381bf8bf41036f5dadd0172/syscallex/exec_windows.go#L138-L141

changing attr.Sys... to sys... do the deal.

zerobyted avatar Feb 09 '20 04:02 zerobyted