Signed-off-by: nickcooper-zhangtonghao <n...@opencloud.tech> --- utilities/ovs-tcpdump.in | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/utilities/ovs-tcpdump.in b/utilities/ovs-tcpdump.in index c189bc8..d03568d 100755 --- a/utilities/ovs-tcpdump.in +++ b/utilities/ovs-tcpdump.in @@ -432,9 +432,12 @@ def main(): print(data) raise KeyboardInterrupt except KeyboardInterrupt: - pipes.terminate() + if pipes.poll() is None: + pipes.terminate() + ovsdb.destroy_mirror('m%s' % interface, ovsdb.port_bridge(interface)) ovsdb.destroy_port(mirror_interface, ovsdb.port_bridge(interface)) + sys.exit(1) except Exception: print("Unable to tear down the ports and mirrors.") print("Please use ovs-vsctl to remove the ports and mirrors created.") -- 1.8.3.1 _______________________________________________ dev mailing list d...@openvswitch.org https://mail.openvswitch.org/mailman/listinfo/ovs-dev