Files
vm/rpc/runtime/subprocess/non_linux_stopper.go
zeekay 169bc81366 fix: resolve proto import paths and test compilation issues
- Fix dag package imports to use vm/proto/pb/dag instead of node/proto
- Fix api/health test to use atomic.Atomic from github.com/luxfi/atomic
- Fix components/message test to use crypto.RandomBytes
- Fix chains/manager to use correct EngineType constant
2026-01-11 20:58:38 -08:00

30 lines
540 B
Go

// Copyright (C) 2019-2025, Lux Industries, Inc. All rights reserved.
// See the file LICENSE for licensing terms.
//go:build !linux
// +build !linux
package subprocess
import (
"context"
"os/exec"
"github.com/luxfi/log"
)
func NewCmd(path string, args ...string) *exec.Cmd {
return exec.Command(path, args...)
}
func stop(_ context.Context, log log.Logger, cmd *exec.Cmd) {
err := cmd.Process.Kill()
if err == nil {
log.Debug("subprocess was killed")
} else {
log.Error("subprocess kill failed",
"error", err,
)
}
}