Added two new arguments to epan_init() and proto_init() to
[obnox/wireshark/wip.git] / file.h
diff --git a/file.h b/file.h
index 070f3c1cc6eba21cea68b52bc026b007b23cce7d..a71c7e556a2e3ee449c8033034a2d24d11ddf243 100644 (file)
--- a/file.h
+++ b/file.h
@@ -1,7 +1,7 @@
 /* file.h
  * Definitions for file structures and routines
  *
- * $Id: file.h,v 1.76 2000/08/21 15:45:21 deniel Exp $
+ * $Id: file.h,v 1.81 2001/02/11 09:28:15 guy Exp $
  *
  * Ethereal - Network traffic analyzer
  * By Gerald Combs <gerald@zing.org>
 #endif
 
 #include "wiretap/wtap.h"
-
-#ifdef HAVE_LIBPCAP
-#include <pcap.h>
-#endif
-
-#include "dfilter.h"
-#include "gtk/colors.h"                /* XXX */
+#include "dfilter/dfilter.h"
 #include "print.h"
-
 #include <errno.h>
+#include <epan.h>
 
 #ifdef HAVE_LIBZ
 #include "zlib.h"
@@ -55,8 +49,6 @@
 #define file_close fclose
 #endif /* HAVE_LIBZ */
 
-typedef struct bpf_program bpf_prog;
-
 /* Current state of file. */
 typedef enum {
        FILE_CLOSED,            /* No file open */
@@ -76,6 +68,7 @@ typedef struct _capture_file {
   int          lnk_t;     /* Link-layer type with which to save capture */
   guint32      vers;      /* Version.  For tcpdump minor is appended to major */
   guint32      count;     /* Packet count */
+  gboolean     drops_known; /* TRUE if we know how many packets were dropped */
   guint32      drops;     /* Dropped packets */
   guint32      esec;      /* Elapsed seconds */
   guint32      eusec;     /* Elapsed microseconds */
@@ -86,13 +79,12 @@ typedef struct _capture_file {
   gchar       *save_file; /* File that user saved capture to */
   int          save_file_fd; /* File descriptor for saved file */
   wtap        *wth;       /* Wiretap session */
-  dfilter     *rfcode;    /* Compiled read filter program */ 
+  dfilter_t   *rfcode;    /* Compiled read filter program */ 
   gchar       *dfilter;   /* Display filter string */
-  colfilter   *colors;   /* Colors for colorizing packet window */
-  dfilter     *dfcode;    /* Compiled display filter program */ 
+  struct _colfilter   *colors;   /* Colors for colorizing packet window */
+  dfilter_t   *dfcode;    /* Compiled display filter program */ 
 #ifdef HAVE_LIBPCAP
   gchar       *cfilter;   /* Capture filter string */
-  bpf_prog     fcode;     /* Compiled capture filter program */
 #endif
   gchar       *sfilter;   /* Search filter string */
   gboolean     sbackward;  /* TRUE if search is backward, FALSE if forward */
@@ -106,6 +98,7 @@ typedef struct _capture_file {
   column_info  cinfo;    /* Column formatting information */
   frame_data  *current_frame;  /* Frame data for current frame */
   proto_tree  *protocol_tree; /* Protocol tree for currently selected packet */
+  epan_dissect_t *edt; /* Protocol dissection fo rcurrently selected packet */
   FILE        *print_fh;  /* File we're printing to */
 } capture_file;
 
@@ -131,7 +124,7 @@ void colorize_packets(capture_file *);
 void redissect_packets(capture_file *cf);
 int print_packets(capture_file *cf, print_args_t *print_args);
 void change_time_formats(capture_file *);
-gboolean find_packet(capture_file *cf, dfilter *sfcode);
+gboolean find_packet(capture_file *cf, dfilter_t *sfcode);
 
 typedef enum {
   FOUND_FRAME,         /* found the frame */