From ca8f79df3d8d042806e24a70a738bd5c92b2dc90 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Sun, 24 Feb 2002 06:45:14 +0000 Subject: Get rid of "init_all_protocols()"; instead, have a routine "init_dissection()" which calls "epan_conversation_init()", does the work that "init_all_protocols()" did, and then calls "reassemble_init()", so that the standard sequence of dissection initialization is done in one place, rather than having multiple places call the same sequence of routines. svn path=/trunk/; revision=4797 --- tethereal.c | 29 +++++------------------------ 1 file changed, 5 insertions(+), 24 deletions(-) (limited to 'tethereal.c') diff --git a/tethereal.c b/tethereal.c index 33d7b82a7e..3c0b187272 100644 --- a/tethereal.c +++ b/tethereal.c @@ -1,6 +1,6 @@ /* tethereal.c * - * $Id: tethereal.c,v 1.125 2002/02/24 06:01:01 guy Exp $ + * $Id: tethereal.c,v 1.126 2002/02/24 06:45:13 guy Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs @@ -102,7 +102,6 @@ #include "pcap-util.h" #endif #include -#include "reassemble.h" #include #include "register.h" #include "conditions.h" @@ -811,17 +810,8 @@ capture(volatile int packet_count, int out_file_type) struct pcap_stat stats; gboolean dump_ok; - /* Initialize the table of conversations. */ - epan_conversation_init(); - - /* Initialize protocol-specific variables */ - init_all_protocols(); - - /* Initialize the common data structures for fragment reassembly. - Must be done *after* "init_all_protocols()", as "init_all_protocols()" - may free up space for fragments, which it finds by using the - data structures that "reassemble_init()" frees. */ - reassemble_init(); + /* Initialize all data structures used for dissection. */ + init_dissection(); ld.linktype = WTAP_ENCAP_UNKNOWN; ld.pdh = NULL; @@ -1748,17 +1738,8 @@ open_cap_file(char *fname, gboolean is_tempfile, capture_file *cf) /* The open succeeded. Fill in the information for this file. */ - /* Initialize the table of conversations. */ - epan_conversation_init(); - - /* Initialize protocol-specific variables */ - init_all_protocols(); - - /* Initialize the common data structures for fragment reassembly. - Must be done *after* "init_all_protocols()", as "init_all_protocols()" - may free up space for fragments, which it finds by using the - data structures that "reassemble_init()" frees. */ - reassemble_init(); + /* Initialize all data structures used for dissection. */ + init_dissection(); cf->wth = wth; cf->filed = fd; -- cgit v1.2.3