Hi List,

I was testing the flow-tools v0.68 off the FreeBSD 6.0 ports when I ran
into a problem regarding an excess comma (,)  on the fields when trying
to export ft files into MySQL or ASCII without using the UNIX_SECS
column.

See:
http://mailman.splintered.net/pipermail/flow-tools/2006-
February/003138.html

I tried a bit of code checking and the culprit seems to be an
uninitialized "comma" variable on flow-export.c "fmt_xfields_type".

<snip>
--- flow-tools-0.68/src/flow-export.c.orig      Mon Feb 13 15:32:59 2006
+++ flow-tools-0.68/src/flow-export.c   Mon Feb 13 16:44:54 2006
@@ -964,6 +964,7 @@
   int comma;

   buf[0] = 0;
+  comma = 0;

   if (xfield & FT_XFIELD_UNIX_SECS) {
     strcat(buf, FT_XFIELD_ASC_UNIX_SECS);
<snip>

The 'comma' might have been getting a random value off an uninitialized
memory chunk (other than the implied zero), hence, the seemingly "always
on" condition when not using UNIX_SECS.

Thanks,

Roy

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

Reply via email to