bugfix to #649: first convert to microseconds, then eventually swap byte ordering (not the other way round)

svn path=/trunk/; revision=16925
This commit is contained in:
Ulf Lamping 2005-12-31 11:48:32 +00:00
parent a2fe0e2b0a
commit 851692e8fb
1 changed files with 1 additions and 1 deletions

View File

@ -810,7 +810,7 @@ static gboolean snoop_dump(wtap_dumper *wdh,
rec_hdr.rec_len = g_htonl(reclen);
rec_hdr.cum_drops = 0;
rec_hdr.ts_sec = g_htonl(phdr->ts.secs);
rec_hdr.ts_usec = g_htonl(phdr->ts.nsecs) / 1000;
rec_hdr.ts_usec = g_htonl(phdr->ts.nsecs / 1000);
nwritten = fwrite(&rec_hdr, 1, sizeof rec_hdr, wdh->fh);
if (nwritten != sizeof rec_hdr) {
if (nwritten == 0 && ferror(wdh->fh))