aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStig Bjørlykke <stig@bjorlykke.org>2008-03-26 16:56:45 +0000
committerStig Bjørlykke <stig@bjorlykke.org>2008-03-26 16:56:45 +0000
commitaecd4254c6fbecf225934c938525b14118c77853 (patch)
tree9bd1170c50ed6758d650694fe6ebdb60f2452b0c
parent4d1463f62dce36a6183b36b6aa2b26b609fd7386 (diff)
Do not add packet length twice to cum_bytes when having a TIME REF frame.
This fixes bug 2387. svn path=/trunk/; revision=24730
-rw-r--r--file.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/file.c b/file.c
index 699729fb8c..aec25b39be 100644
--- a/file.c
+++ b/file.c
@@ -982,15 +982,15 @@ add_packet_to_packet_list(frame_data *fdata, capture_file *cf,
/* This frame either passed the display filter list or is marked as
a time reference frame. All time reference frames are displayed
even if they dont pass the display filter */
- /* if this was a TIME REF frame we should reset the cul bytes field */
if(edt->pi.fd->flags.ref_time){
+ /* if this was a TIME REF frame we should reset the cul bytes field */
cum_bytes = fdata->pkt_len;
- fdata->cum_bytes = cum_bytes;
+ fdata->cum_bytes = cum_bytes;
+ } else {
+ /* increase cum_bytes with this packets length */
+ cum_bytes += fdata->pkt_len;
}
- /* increase cum_bytes with this packets length */
- cum_bytes += fdata->pkt_len;
-
epan_dissect_fill_in_columns(edt);
/* If we haven't yet seen the first frame, this is it.