Ethereal-dev: Re: [ethereal-dev] ethereal packet-smb.c

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: guy@xxxxxxxxxx (Guy Harris)
Date: Mon, 10 May 1999 18:39:22 -0700 (PDT)
> Add decoding of DOS-format dates and times (one of the N different
> date/time formats used in SMB...).

Note that the most recent format is a 64-bit integer that, when
positive, represents the number of 100ns units since the Win32 FILETIME
epoch ("the beginning of the year 1601 AD in the Gregorian calendar").

We can probably handle that either by:

	1) doing the arithmetic in floating point;

	2) deciding to support only compilers that have support for a
	   64-bit integral data type (most modern UNIX C compilers have
	   this, I think; GCC and Sun's C compiler both support
	   "long long int" even on 32-bit processors);

	3) doing the 64-bit arithmetic, on 32-bit platforms, "by hand"
	   (in effect, doing what, say, GCC does, by hand).

There may be other alternatives as well.

Does anybody have a preference for one of those approaches?