aboutsummaryrefslogtreecommitdiffstats
path: root/gtk/summary_dlg.c
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2002-08-31 00:40:46 +0000
committerGerald Combs <gerald@wireshark.org>2002-08-31 00:40:46 +0000
commit074cb0f6d2e05ad72d6888b3cde0f1c8fed36c8b (patch)
treede55b5784243f3a597d215265eb9a5e05a20ffa1 /gtk/summary_dlg.c
parent284d6547e2790c0e517da9a655e0e1d4e220d8c3 (diff)
Cast the Mbits/s calculation as a float, so that we display the value
correctly for large captures. svn path=/trunk/; revision=6150
Diffstat (limited to 'gtk/summary_dlg.c')
-rw-r--r--gtk/summary_dlg.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gtk/summary_dlg.c b/gtk/summary_dlg.c
index 1f057f9c13..235ecd83d5 100644
--- a/gtk/summary_dlg.c
+++ b/gtk/summary_dlg.c
@@ -1,7 +1,7 @@
/* summary_dlg.c
* Routines for capture file summary window
*
- * $Id: summary_dlg.c,v 1.13 2002/08/28 21:03:49 jmayer Exp $
+ * $Id: summary_dlg.c,v 1.14 2002/08/31 00:40:46 gerald Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@zing.org>
@@ -162,7 +162,8 @@ summary_open_cb(GtkWidget *w _U_, gpointer d _U_)
add_string_to_box(string_buff, data_box);
/* MBit per second */
- snprintf(string_buff, SUM_STR_MAX, "Avg. Mbit/sec: %.3f", summary.bytes*8/(seconds*1000*1000));
+ snprintf(string_buff, SUM_STR_MAX, "Avg. Mbit/sec: %.3f",
+ summary.bytes * 8.0 / (seconds * 1000.0 * 1000.0) );
add_string_to_box(string_buff, data_box);
}