2 * Synchronisation between Ethereal capture parent and child instances
6 * Ethereal - Network traffic analyzer
7 * By Gerald Combs <gerald@ethereal.com>
8 * Copyright 1998 Gerald Combs
10 * This program is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU General Public License
12 * as published by the Free Software Foundation; either version 2
13 * of the License, or (at your option) any later version.
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
20 * You should have received a copy of the GNU General Public License
21 * along with this program; if not, write to the Free Software
22 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
28 * Sync mode capture (internal interface).
30 * Will start a new Ethereal child instance which will do the actual capture
34 #ifndef __CAPTURE_SYNC_H__
35 #define __CAPTURE_SYNC_H__
38 * Start a new capture session.
39 * Create a capture child which is doing the real capture work.
40 * The various capture_input_... functions will be called, if something had
43 * Most of the parameters are passed through the global capture_opts.
45 * @param capture_opts the options
46 * @return TRUE if a capture could be started, FALSE if not
49 sync_pipe_start(capture_options *capture_opts);
51 /** User wants to stop capturing, gracefully close the capture child */
53 sync_pipe_stop(capture_options *capture_opts);
55 /** User wants to stop the program, just kill the child as soon as possible */
57 sync_pipe_kill(capture_options *capture_opts);
60 /** the child has opened a new capture file, notify the parent */
62 sync_pipe_filename_to_parent(const char *filename);
64 /** the child captured some new packets, notify the parent */
66 sync_pipe_packet_count_to_parent(int packet_count);
68 /** the child stopped capturing, notify the parent */
70 sync_pipe_drops_to_parent(int drops);
72 /** the child encountered an error, notify the parent */
74 sync_pipe_errmsg_to_parent(const char *errmsg);
77 #endif /* capture_sync.h */