Skip to content

Commit

Permalink
Minor fix for background flag
Browse files Browse the repository at this point in the history
  • Loading branch information
iann0036 committed Apr 25, 2021
1 parent b3a82b4 commit c7e3a88
Showing 1 changed file with 0 additions and 14 deletions.
14 changes: 0 additions & 14 deletions iamlivecore/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -172,20 +172,6 @@ func RunWithArgs(setIni bool, profile string, failsOnly bool, outputFile string,
backgroundFlag = &background
forceWildcardResourceFlag = &forceWildcardResource

if *backgroundFlag {
args := os.Args[1:]
for i := 0; i < len(args); i++ {
if args[i] == "-background" || args[i] == "--background" {
args = append(args[:i], args[i+1:]...)
break
}
}
cmd := exec.Command(os.Args[0], args...)
cmd.Start()
fmt.Println(cmd.Process.Pid)
os.Exit(0)
}

if *cpuProfileFlag != "" {
f, err := os.Create(*cpuProfileFlag)
if err != nil {
Expand Down

0 comments on commit c7e3a88

Please sign in to comment.