wsutil: introduce ws_pipe_close() helper and use it to terminate mmdbresolve
[metze/wireshark/wip.git] / extcap.c
index 7c65267fc9aa85bdb9bcfc6f6d4bba4e84f80ebe..7b468be5f88fe8124cddfa22584bb93694e0bf70 100644 (file)
--- a/extcap.c
+++ b/extcap.c
@@ -1199,10 +1199,7 @@ void extcap_if_cleanup(capture_options *capture_opts, gchar **errormsg)
 
         if (interface_opts->extcap_pid != WS_INVALID_PID)
         {
-#ifdef _WIN32
-            TerminateProcess(interface_opts->extcap_pid, 0);
-#endif
-            g_spawn_close_pid(interface_opts->extcap_pid);
+            ws_pipe_close((ws_pipe_t *) interface_opts->extcap_pipedata);
             interface_opts->extcap_pid = WS_INVALID_PID;
 
             g_free(interface_opts->extcap_pipedata);