wtap *wth; /* Wiretap session */
dfilter_t *rfcode; /* Compiled read (display) filter program */
gchar *dfilter; /* Display filter string */
+ gboolean redissecting; /* TRUE if currently redissecting (cf_redissect_packets) */
/* search */
gchar *sfilter; /* Search filter string */
gboolean sbackward; /* TRUE if search is backward, FALSE if forward */
cf->count++;
cf->f_datalen = offset + phdr->caplen;
fdata->num = cf->count;
- row = add_packet_to_packet_list(fdata, cf, dfcode, pseudo_header, buf, TRUE);
+ if (!cf->redissecting) {
+ row = add_packet_to_packet_list(fdata, cf, dfcode, pseudo_header, buf, TRUE);
+ }
} else {
/* XXX - if we didn't have read filters, or if we could avoid
allocating the "frame_data" structure until we knew whether
which might cause the state information to be constructed differently
by that dissector. */
+ /* We might receive new packets while redissecting, and we don't
+ want to dissect those before their time. */
+ cf->redissecting = TRUE;
+
/* Initialize all data structures used for dissection. */
init_dissection();
}
prev_frame = fdata;
}
+ /* We are done redissecting the packet list. */
+ cf->redissecting = FALSE;
+
/* Re-sort the list using the previously selected order */
packet_list_set_sort_column();