Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 16 Sep 2010 14:30:32 +0000 (UTC)
From:      Gleb Smirnoff <glebius@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org
Subject:   svn commit: r212734 - stable/8/sys/netgraph/netflow
Message-ID:  <201009161430.o8GEUWne093939@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: glebius
Date: Thu Sep 16 14:30:32 2010
New Revision: 212734
URL: http://svn.freebsd.org/changeset/base/212734

Log:
  MFhead 210500:
    Zero padding fields of netflow records. This helps to reduce
    size of compressed export logs.
  
    Requested by: Alexey Illarionov <littlesavage orionet.ru>

Modified:
  stable/8/sys/netgraph/netflow/netflow.c

Modified: stable/8/sys/netgraph/netflow/netflow.c
==============================================================================
--- stable/8/sys/netgraph/netflow/netflow.c	Thu Sep 16 13:49:10 2010	(r212733)
+++ stable/8/sys/netgraph/netflow/netflow.c	Thu Sep 16 14:30:32 2010	(r212734)
@@ -167,6 +167,7 @@ get_export_dgram(priv_p priv)
 		dgram = mtod(m, struct netflow_v5_export_dgram *);
 		dgram->header.count = 0;
 		dgram->header.version = htons(NETFLOW_V5);
+		dgram->header.pad = 0;
 
 	}
 
@@ -644,6 +645,8 @@ export_add(item_p item, struct flow_entr
 	rec->tos      = fle->f.r.r_tos;
 	rec->dst_mask = fle->f.dst_mask;
 	rec->src_mask = fle->f.src_mask;
+	rec->pad1     = 0;
+	rec->pad2     = 0;
 
 	/* Not supported fields. */
 	rec->src_as = rec->dst_as = 0;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201009161430.o8GEUWne093939>