Skip to content

Commit

Permalink
Works either way, but it's more correct to send SIGTERM
Browse files Browse the repository at this point in the history
This signal terminates tshark or dumpcap. SIGINT will do the job too,
and tshark will catch both signals, but SIGTERM is intended for
programmatic signalling.
  • Loading branch information
gcla committed Oct 29, 2020
1 parent 4aacb97 commit 8cbd582
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pcap/cmds_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,5 @@ func (c *Command) Kill() error {
if c.Cmd.Process == nil {
return errors.WithStack(ProcessNotStarted{Command: c.Cmd})
}
return syscall.Kill(-c.Cmd.Process.Pid, syscall.SIGINT)
return syscall.Kill(-c.Cmd.Process.Pid, syscall.SIGTERM)
}

0 comments on commit 8cbd582

Please sign in to comment.