Skip to content

Commit

Permalink
fix: wait for cmd
Browse files Browse the repository at this point in the history
  • Loading branch information
BlackDark committed Oct 29, 2024
1 parent 091525c commit 2036a4a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,8 @@ func executeProgram(collectTimeSeconds int) bytes.Reader {
log.Fatalf("Failed to run turbostat: %v", err)
}

cmd.Wait()

lines := bytes.Split(out.Bytes(), []byte("\n"))

log.Debugf("Command output: %s", lines)
Expand Down

0 comments on commit 2036a4a

Please sign in to comment.