On Dec 15, "To Flow-tools Mailing List" wrote:

> I am building a new flow cruncher on an amd64, and I've run into a problem
> with flow-print.  The dates are garbled:

[snip]

> I'm going to plan on diving into the source, but I first wanted to check if 
> anybody else is having these problems or if somebody knew right away where to
> look.

Here's the patch I came up with:

-----------------------------------------------------------------------------
--- ftlib.h     Wed Dec 15 16:13:30 2004
+++ ftlib.h     Wed Dec 15 16:17:11 2004
@@ -414,8 +414,8 @@
 };
 
 struct fttime {
-  u_int32 secs;
-  u_int32 msecs;
+  time_t secs;
+  time_t msecs;
 };
 
 struct ftver {
-----------------------------------------------------------------------------

The code makes some assumptions about secs being cast-able to (time_t*),
which is 32 bits on x86 but 64 bits on x86-64.  So, the upside of changing
the ftlib struct itself is that it should be more portable.  The downside
is that I don't know if I just unwittingly screwed stuff up.  I have done
*minimal testing* with this change, so I don't recommend that it be picked
up immediately...I'm hoping to rouse the author and let him make the
appropriate fix himself :)

Mike
_______________________________________________
Flow-tools mailing list
[EMAIL PROTECTED]
http://mailman.splintered.net/mailman/listinfo/flow-tools

Reply via email to