Skip to content
Success

Changes

Summary

  1. tcpdump/dumpcap: move kill_rm_pidfile to inc file (details)
Commit 30d9b9265fe545b36f3938ce36e885a441d99d72 by Oliver Smith
tcpdump/dumpcap: move kill_rm_pidfile to inc file

Move kill_rm_pidfile out of the 4 ttcn3 tcpdump/dumpcap scripts into a
shared include file. Use the version of the function that only tries to
kill the command with sudo if it was started with sudo.

This fixes dumpcap not stopping if:

* it was started with ttcn3-tcpdump-start.sh (despite the name it will
  start dumpcap instead of tcpdump if dumpcap was found), where it gets
  started without sudo, and

* no rule is in the user's sudoers file is set to run kill as root with
  NOPASSWD.

Change-Id: Ia63c37b54fb42a8c64a676334cef6f9df4152e18
The file was modifiedttcn3-dumpcap-stop.sh
The file was modifiedttcn3-tcpdump-start.sh
The file was modifiedttcn3-tcpdump-stop.sh
The file was modifiedttcn3-dumpcap-start.sh
The file was added_scripts/tcpdump-dumpcap.inc.sh