aboutsummaryrefslogtreecommitdiffstats
path: root/capture_opts.h
diff options
context:
space:
mode:
authorTomasz Moń <desowin@gmail.com>2022-08-11 06:23:16 +0200
committerTomasz Moń <desowin@gmail.com>2022-08-12 06:50:09 +0200
commit0bca2419d6abb981a8c79d320cda376996b0af32 (patch)
tree718d2d24b70d7cb29d53bb98609ebec86e4c7bba /capture_opts.h
parent25bb87a7811f783665b844bd84aeba668d46866b (diff)
extcap: Do not drain stderr on process exit
Extcap child watch callback assumed that the stderr pipe is broken. However the stdout and stderr pipes are not necessarily broken if the child process spawned new processes that inherited standard handles. Do not drain stderr in busy loop to prevent UI freeze. Stop capture session only when all extcap watches are removed. Remove stdout and stderr watches on capture stop timer (30 seconds) expiration, even if the pipes are not broken. Do not rely only on 0 bytes read to cease reading stdout and stderr. Stop reading if the status is anything else than G_IO_STATUS_NORMAL (especially it can be G_IO_STATUS_EOF).
Diffstat (limited to 'capture_opts.h')
-rw-r--r--capture_opts.h1
1 files changed, 0 insertions, 1 deletions
diff --git a/capture_opts.h b/capture_opts.h
index 2508b850b7..130735b761 100644
--- a/capture_opts.h
+++ b/capture_opts.h
@@ -211,7 +211,6 @@ typedef struct interface_options_tag {
GPid extcap_pid; /* pid of running process or WS_INVALID_PID */
gpointer extcap_pipedata;
GString *extcap_stderr;
- guint extcap_child_watch;
guint extcap_stdout_watch;
guint extcap_stderr_watch;
#ifdef _WIN32