diff options
author | Michael Tüxen <tuexen@fh-muenster.de> | 2012-04-15 11:11:36 +0000 |
---|---|---|
committer | Michael Tüxen <tuexen@fh-muenster.de> | 2012-04-15 11:11:36 +0000 |
commit | bacf81ff06eef90f8180aa8f46c7f20bc59f0c41 (patch) | |
tree | 92a888b0f0e32447852a6408b42d196817997256 /pcapio.c | |
parent | 587e0213eb0bf9f62f174f4ad706f0dfda864768 (diff) | |
download | wireshark-bacf81ff06eef90f8180aa8f46c7f20bc59f0c41.tar.gz wireshark-bacf81ff06eef90f8180aa8f46c7f20bc59f0c41.tar.bz2 wireshark-bacf81ff06eef90f8180aa8f46c7f20bc59f0c41.zip |
Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7048
Write timetamps for the interface statistic blocks the way specified
by http://www.winpcap.org/ntar/draft/PCAP-DumpFileFormat.html
svn path=/trunk/; revision=42080
Diffstat (limited to 'pcapio.c')
-rw-r--r-- | pcapio.c | 14 |
1 files changed, 12 insertions, 2 deletions
@@ -698,16 +698,26 @@ libpcap_write_interface_statistics_block(FILE *fp, } if (isb_starttime !=0) { + guint32 high, low; + option.type = ISB_STARTTIME; option.value_length = sizeof(guint64); + high = (guint32)((isb_starttime>>32) & 0xffffffff); + low = (guint32)(isb_starttime & 0xffffffff); WRITE_DATA(fp, &option, sizeof(struct option), *bytes_written, err); - WRITE_DATA(fp, &isb_starttime, sizeof(guint64), *bytes_written, err); + WRITE_DATA(fp, &high, sizeof(guint32), *bytes_written, err); + WRITE_DATA(fp, &low, sizeof(guint32), *bytes_written, err); } if (isb_endtime !=0) { + guint32 high, low; + option.type = ISB_ENDTIME; option.value_length = sizeof(guint64); + high = (guint32)((isb_endtime>>32) & 0xffffffff); + low = (guint32)(isb_endtime & 0xffffffff); WRITE_DATA(fp, &option, sizeof(struct option), *bytes_written, err); - WRITE_DATA(fp, &isb_endtime, sizeof(guint64), *bytes_written, err); + WRITE_DATA(fp, &high, sizeof(guint32), *bytes_written, err); + WRITE_DATA(fp, &low, sizeof(guint32), *bytes_written, err); } if (stats_retrieved) { /* */ |