diff options
author | Anders Broman <anders.broman@ericsson.com> | 2005-08-03 20:37:28 +0000 |
---|---|---|
committer | Anders Broman <anders.broman@ericsson.com> | 2005-08-03 20:37:28 +0000 |
commit | 32f826a7cea1a6b72d1eea03866274fc39b59580 (patch) | |
tree | 1dbe75d349faea3f8f3569d9da7b17839fe6d352 /epan/nstime.h | |
parent | d0811b3d350ac7c34a07c3f9b8d447b39804aa81 (diff) | |
download | wireshark-32f826a7cea1a6b72d1eea03866274fc39b59580.tar.gz |
From Richard van der Hoff:
Among the improvements are:
- fixes to call-tracking (it's now less likely to confuse two separate
calls, for instance)
- improvements to Information Element dissection (clearer dissection,
dissects more IE types, easier to extend)
- you can now filter on the content of DTMF packets
- Analysis of timestamps (calculation of absolute timestamp, and packet
lateness).
- fixed a couple of assertion failures in subtle corner-cases.
negative relative times:
- get_timedelta()
- addtime()
- ftype-time.c:relative_val_from_unparsed()
I've also moved get_timedelta() and addtime() out of calldata.c into a
new file, epan/nstime.c, as I needed to use them in a dissector I'm
working on (and they therefore needed to go into libethereal).
svn path=/trunk/; revision=15201
Diffstat (limited to 'epan/nstime.h')
-rw-r--r-- | epan/nstime.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/epan/nstime.h b/epan/nstime.h index 188b96b450..af6a8c7e10 100644 --- a/epan/nstime.h +++ b/epan/nstime.h @@ -32,4 +32,27 @@ typedef struct { int nsecs; } nstime_t; +/* functions */ + +/* calculate the delta between two times + * + * delta = b-a + * + * Note that it is acceptable for two or more of the arguments to point at the + * same structure. + */ +extern void get_timedelta(nstime_t *delta, const nstime_t *b, const nstime_t *a ); + +/* calculate the sum of two times + * + * sum = a+b + * + * Note that it is acceptable for two or more of the arguments to point at the + * same structure. + */ +extern void get_timesum(nstime_t *sum, const nstime_t *b, const nstime_t *a ); + +/* sum += a */ +#define addtime(sum, a) get_timesum(sum, sum, b) + #endif /* __NSTIME_H__ */ |