diff options
author | Stephen Fisher <steve@stephen-fisher.com> | 2007-03-23 18:08:17 +0000 |
---|---|---|
committer | Stephen Fisher <steve@stephen-fisher.com> | 2007-03-23 18:08:17 +0000 |
commit | 6d8d2854c8cf998605e041987610986d09375c6a (patch) | |
tree | 49c7db39b4c44d02429daa16149f2ba63678af4e /epan/column.c | |
parent | 62f88a4a04d8e300ff108f6164e9016e8cdcc9c3 (diff) |
From Sake Blok:
Fix for bug #491: Unexpected frame.time_delta behavior
This patch ... fixes bug 491. It does this by changing the
behaviour of the frame.time_delta field so it reflects the delta
time between captured packets (tshark already did this). To keep
the delta time between displayed packets, the field
frame.time_delta_displayed is created.
svn path=/trunk/; revision=21154
Diffstat (limited to 'epan/column.c')
-rw-r--r-- | epan/column.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/epan/column.c b/epan/column.c index f84b338933..135b57e8e0 100644 --- a/epan/column.c +++ b/epan/column.c @@ -51,6 +51,7 @@ col_format_to_string(gint fmt) { "%At", "%Yt", "%Tt", + "%Gt", "%s", "%rs", "%us", @@ -116,6 +117,7 @@ static const gchar *dlist[NUM_COL_FMTS] = { "Absolute time", /* COL_ABS_TIME */ "Absolute date and time", /* COL_ABS_DATE_TIME */ "Delta time", /* COL_DELTA_TIME */ + "Delta time displayed", /* COL_DELTA_TIME_DIS */ "Source address", /* COL_DEF_SRC */ "Src addr (resolved)", /* COL_RES_SRC */ "Src addr (unresolved)", /* COL_UNRES_SRC */ @@ -355,6 +357,7 @@ get_timestamp_column_longest_string(gint type, gint precision) break; case(TS_RELATIVE): /* fallthrough */ case(TS_DELTA): + case(TS_DELTA_DIS): switch(precision) { case(TS_PREC_AUTO_SEC): case(TS_PREC_FIXED_SEC): @@ -472,6 +475,9 @@ get_column_longest_string(gint format) case COL_DELTA_TIME: return get_timestamp_column_longest_string(TS_DELTA, timestamp_get_precision()); break; + case COL_DELTA_TIME_DIS: + return get_timestamp_column_longest_string(TS_DELTA_DIS, timestamp_get_precision()); + break; case COL_DEF_SRC: case COL_RES_SRC: case COL_UNRES_SRC: @@ -581,6 +587,7 @@ get_column_char_width(gint format) #define TIME_ABS 2 #define DATE_TIME_ABS 3 #define TIME_DEL 4 +#define TIME_DEL_DIS 5 #define RES_DEF 0 #define RES_DO 1 @@ -672,6 +679,9 @@ get_column_format_from_str(gchar *str) { case 'T': time_off = TIME_DEL; break; + case 'G': /* Todo: use a better letter for time since last displayed packet */ + time_off = TIME_DEL_DIS; + break; case 'L': return COL_PACKET_LENGTH; break; |