aboutsummaryrefslogtreecommitdiffstats
path: root/gtk
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2005-09-11 22:25:33 +0000
committerGuy Harris <guy@alum.mit.edu>2005-09-11 22:25:33 +0000
commitd8873511a77f2b58b420b83d719b204e4e18d127 (patch)
tree921a697c78e514c52d1a5ff85ed6f3e0b880dca0 /gtk
parent51875708f2d6af1b8b645e3ad4874b309bcf4d2c (diff)
Frame numbers are unsigned, and they start at 1; 0 is what's used for
"unknown" for frame numbers. Note that in epan/frame_data.h, and make the frame number in experts unsigned, and use 0 for "unknown", and display it as an unsigned number - and, if it's 0, don't display it at all. Fix the signature of "expert_dlg_draw()" to match what a tap's draw routine's signature is expected to be. svn path=/trunk/; revision=15760
Diffstat (limited to 'gtk')
-rw-r--r--gtk/expert_dlg.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/gtk/expert_dlg.c b/gtk/expert_dlg.c
index 3a60b391bf..3e7154878b 100644
--- a/gtk/expert_dlg.c
+++ b/gtk/expert_dlg.c
@@ -162,8 +162,9 @@ int expert_dlg_packet(void *tapdata, packet_info *pinfo, epan_dissect_t *edt, co
}
void
-expert_dlg_draw(expert_tapdata_t *etd)
+expert_dlg_draw(void *data)
{
+ expert_tapdata_t *etd = data;
int row;
char *strp;
expert_info_t *ei;
@@ -192,8 +193,12 @@ expert_dlg_draw(expert_tapdata_t *etd)
gtk_clist_set_row_data(etd->table, row, ei);
/* packet number */
- strp=se_strdup_printf("%d", ei->packet_num);
- gtk_clist_set_text(etd->table, row, 0, strp);
+ if(ei->packet_num) {
+ strp=se_strdup_printf("%u", ei->packet_num);
+ gtk_clist_set_text(etd->table, row, 0, strp);
+ } else {
+ gtk_clist_set_text(etd->table, row, 0, "-");
+ }
/* severity */
strp=se_strdup(val_to_str(ei->severity, expert_severity_vals, "Unknown severity (%u)"));