fix windows compilation error

This commit is contained in:
Asim Aslam 2019-11-21 11:19:52 +00:00
parent 11d81221cc
commit 212144d658

View File

@ -6,7 +6,6 @@ import (
"os"
"os/exec"
"strconv"
"syscall"
"github.com/micro/go-micro/runtime/process"
)
@ -15,13 +14,13 @@ type Process struct {
}
func (p *Process) Exec(exe *process.Executable) error {
cmd := exec.Command(exe.Binary.Path)
cmd := exec.Command(exe.Package.Path)
return cmd.Run()
}
func (p *Process) Fork(exe *process.Executable) (*process.PID, error) {
// create command
cmd := exec.Command(exe.Binary.Path, exe.Args...)
cmd := exec.Command(exe.Package.Path, exe.Args...)
// set env vars
cmd.Env = append(cmd.Env, exe.Env...)