github.com/wallyworld/juju@v0.0.0-20161013125918-6cf1bc9d917a/worker/uniter/runner/process_nix_test.go (about) 1 // Copyright 2014 Canonical Ltd. 2 // Copyright 2014 Cloudbase Solutions SRL 3 // Licensed under the AGPLv3, see LICENCE file for details. 4 5 // +build !windows 6 7 package runner_test 8 9 import ( 10 "syscall" 11 ) 12 13 func processExists(pid int) bool { 14 err := syscall.Kill(pid, 0) 15 if err != nil { 16 return false 17 } 18 return true 19 }