diff mbox

[ovs-dev,v2,2/4] ovs-tcpdump: should't halt when dumping traffic.

Message ID 1479115454-48163-3-git-send-email-nic@opencloud.tech
State Accepted
Headers show

Commit Message

nickcooper-zhangtonghao Nov. 14, 2016, 9:24 a.m. UTC
when sys.stdin is passed to tcpdump via pipe,
it will cause tcpdump to halt.

Signed-off-by: nickcooper-zhangtonghao <nic@opencloud.tech>
---
 utilities/ovs-tcpdump.in | 3 ---
 1 file changed, 3 deletions(-)

Comments

Aaron Conole Nov. 14, 2016, 3:35 p.m. UTC | #1
nickcooper-zhangtonghao <nic@opencloud.tech> writes:

> when sys.stdin is passed to tcpdump via pipe,
> it will cause tcpdump to halt.
>
> Signed-off-by: nickcooper-zhangtonghao <nic@opencloud.tech>
> ---

On further investigation, there are other issues around supporting
this properly, so:

Acked-by: Aaron Conole <aconole@redhat.com>
diff mbox

Patch

diff --git a/utilities/ovs-tcpdump.in b/utilities/ovs-tcpdump.in
index 01e1f6d..c189bc8 100755
--- a/utilities/ovs-tcpdump.in
+++ b/utilities/ovs-tcpdump.in
@@ -430,9 +430,6 @@  def main():
             if len(data) == 0:
                 raise KeyboardInterrupt
             print(data)
-            if select.select([sys.stdin], [], [], 0.0)[0]:
-                data_in = sys.stdin.read()
-                pipes.stdin.write(data_in)
         raise KeyboardInterrupt
     except KeyboardInterrupt:
         pipes.terminate()