Fix the ChmodBPF startup item permissions. Handling this within
[obnox/wireshark/wip.git] / timestats.h
index 8f584ef173cb473f3d7f564b10a3a7401cdacd94..6e880d2874a8b50cc35b91709d2f4f4b3d4f0aa7 100644 (file)
@@ -2,10 +2,10 @@
  * Routines and definitions for time statistics
  * Copyrigth 2003 Lars Roland
  *
- * $Id: timestats.h,v 1.1 2003/04/16 07:24:04 guy Exp $
+ * $Id$
  *
- * Ethereal - Network traffic analyzer
- * By Gerald Combs <gerald@ethereal.com>
+ * Wireshark - Network traffic analyzer
+ * By Gerald Combs <gerald@wireshark.org>
  * Copyright 1998 Gerald Combs
  *
  * This program is free software; you can redistribute it and/or
@@ -42,12 +42,13 @@ typedef struct _timestat_t {
 } timestat_t;
 
 /* functions */
-extern void get_timedelta(nstime_t *delta, nstime_t *b, nstime_t *a ); /* delta = b - a */
-extern void addtime(nstime_t *sum, nstime_t *a);                       /* sum += a */
 
-extern gdouble nstime_to_msec(nstime_t *time); /* converts nstime to gdouble, time base is milli seconds*/
+/* Initialize a timestat_t struct */
+extern void time_stat_init(timestat_t *stats);
 
-extern void time_stat_update(timestat_t *stats, nstime_t *delta, packet_info *pinfo);
-extern gdouble get_average(nstime_t *sum, guint32 num);
+/* Update a timestat_t struct with a new sample */
+extern void time_stat_update(timestat_t *stats, const nstime_t *delta, packet_info *pinfo);
+
+extern gdouble get_average(const nstime_t *sum, guint32 num);
 
 #endif