Skip to content

Commit

Permalink
removed path hard coding (#430)
Browse files Browse the repository at this point in the history
  • Loading branch information
abriles1216 authored Nov 14, 2024
1 parent 02ab438 commit 927b197
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions plugins/util/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package util
import (
"os"
"os/exec"
"path/filepath"
"strconv"
"strings"
"sync"
Expand Down Expand Up @@ -45,13 +44,6 @@ func RunSigusr1(executable string) error {
// @param executable string - the binary process name
// @param signal syscall.Signal - the signal type to send
func SendSignal(executable string, signal syscall.Signal) error {

if !filepath.IsAbs(executable) {
// match the full path of the executable
executable = "/usr/bin/" + executable
logger.Debug("Exectutable transformed to %s\n", executable)
}

logger.Debug("Sending %s to %s\n", signal, executable)

pidStr, err := exec.Command("pidof", executable).CombinedOutput()
Expand Down

0 comments on commit 927b197

Please sign in to comment.