# ChangeLog for net-analyzer/flow-tools
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/flow-tools/ChangeLog,v 1.48 2011/03/27 19:35:41 ranger Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/flow-tools/ChangeLog,v 1.49 2011/11/15 21:46:23 jer Exp $
+
+*flow-tools-0.68.5.1 (15 Nov 2011)
+
+ 15 Nov 2011; Jeroen Roovers <jer@gentoo.org>
+ -files/flow-tools-0.67-memleak.patch, -files/flow-tools-0.67-nodebug.patch,
+ -flow-tools-0.68-r5.ebuild, -flow-tools-0.68-r7.ebuild,
+ -flow-tools-0.68-r8.ebuild, -files/flow-tools-0.68-249449-amd64.patch,
+ -files/flow-tools-0.68-another-amd64-casting-fixes.patch,
+ +flow-tools-0.68.5.1.ebuild, -files/flow-tools-0.68-db_tmp.patch,
+ -files/flow-tools-0.68-fix-a-zillion-warnings-updated.diff,
+ -files/flow-tools-0.68-fix-configure.diff:
+ Version bump.
27 Mar 2011; Brent Baude <ranger@gentoo.org> flow-tools-0.68.5-r1.ebuild:
stable ppc, bug 347591
-AUX flow-tools-0.67-memleak.patch 465 RMD160 6e04608d9ce2cd9da945451a668be1e2426eb88a SHA1 68e777246680b23861504aabe7132dc04e2667f7 SHA256 185b1751d4b9208be73917f8dfd90662f61e7fedc617a0dad15cf4141bc473bd
-AUX flow-tools-0.67-nodebug.patch 933 RMD160 fe974a8a69f168783d7c77ca6aaf302010ffcacb SHA1 38ab0c45bb08f327f9efce843691e07eedbc7d9d SHA256 e862d823543f422319c31e305149b25a0d74ffbc9d0ee98ec756a90fc053b373
-AUX flow-tools-0.68-249449-amd64.patch 274 RMD160 8312c57502e4e3c96fcbcc568983bdcd453201f7 SHA1 b9c3f1d2e7d16c9b9445846a2a5e090df2ddd43e SHA256 59b0df2866339c1f0dda8f66b360f5d3d3b532f0a9a0c948403e41b5f94b6e35
-AUX flow-tools-0.68-another-amd64-casting-fixes.patch 2070 RMD160 a46a9eb144c5ca130b3af1351194af212b0fd8c3 SHA1 95d0e154e064cbc67fafab9729b37ef1da3e3bb7 SHA256 ff5a14e7c3999888325c3bee057e40410c3bb600bfb8c15f931094b164799c98
-AUX flow-tools-0.68-db_tmp.patch 574 RMD160 7cecb1da86c762a41c05c1ad2443e16eb825cb40 SHA1 dc489ec81e21ba1578feb4eb60a51c6a29677852 SHA256 f3653d15368356b4b2b64a13ba0eb6d893ec120c43e7bf29f73f05dd5ec57026
-AUX flow-tools-0.68-fix-a-zillion-warnings-updated.diff 19404 RMD160 81535106be145c56a6a201125ad1cd137ec25378 SHA1 fad3da5429d8d3edef5ea9af09cac11484c4b159 SHA256 03991fe055eae71b58d7ac1b7cb1b4cdfe33566e9ee8c0cd99144b583bb2affe
-AUX flow-tools-0.68-fix-configure.diff 4311 RMD160 fd14ccfd4def9c5f5ca77f368c512abaf8ac4a04 SHA1 8ba5adac524978f3662020976bd40b28e3296d57 SHA256 bc0877413e4eb8548219065b4b48dd9104972fa31031735f9c63b203dfb5ab9e
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
AUX flowcapture.confd 1590 RMD160 8c1fc976191bde42950e0b9e7eed98838abd51ad SHA1 34079f52426add558bb117fef62ebff68b36d9bd SHA256 5d5640ff055d555d527c261ada54e044519c8197413719435e6a965a42147fa4
AUX flowcapture.initd 488 RMD160 a0e5688cd49ce9623a3f11bae0fa2d58cc47c609 SHA1 da2024ab2af2cdb0c76f3104d8519cba800983d8 SHA256 125cc865b380427a0e48eb40c3af3d4441ed2a46ac2fd78bdd7768f251feee25
AUX linkme 283 RMD160 663284e66edca80e03d88db3078cd93d6faca452 SHA1 ebf19e1a1b0b7d74ada82e13d87f95cd61651958 SHA256 93cef6b11cb25a9e91b529030e66cd4c709f382993335f2c7252de89c36735da
+DIST flow-tools-0.68.5.1.tar.bz2 914062 RMD160 7bf4f155518673a9821d5f0b05592cb77931eb4b SHA1 4a843aada631650e3777a9b1eeb4ec46562cf0d0 SHA256 80bbd3791b59198f0d20184761d96ba500386b0a71ea613c214a50aa017a1f67
DIST flow-tools-0.68.5.tar.bz2 914600 RMD160 8f228adad56e8a05e2f3ce71c0a1cf3db613c4d7 SHA1 d715efc1a2290c1606c4bb694d6d190830803813 SHA256 39b9d624561dabe0a0ab2db32e8ab9cca7869060f9a7b159ec6fd2253e1e3d7d
-DIST flow-tools-0.68.tar.gz 987151 RMD160 71bfd1a40cb34fae55b2769d93208d13b3b0a927 SHA1 6259263ac4fbf8a9394224e4053393fa756473c7 SHA256 69d5353b339f917fc141919db042b007d5c8d31c9ad1bc2f989a41aa41d629df
-EBUILD flow-tools-0.68-r5.ebuild 2700 RMD160 5055ce755ae70e3c88437fda7c6ebc34a438d772 SHA1 d8412c04499ee7a5156a0e34262c0872fd07e6dc SHA256 425bc8ff5f6e0c353961ef07dc9fa94638d4856bd65311c59194fa1e666a7b68
-EBUILD flow-tools-0.68-r7.ebuild 2743 RMD160 3d9826910b172cb2c5f5dd08ac4b98d226c6bc52 SHA1 78d3c03e25bc314229c7fe6d52989d7358d3eac9 SHA256 c7f684d93aa98c6ef83c944516dfa04aa90fe8351216580bfe52ff18003d6168
-EBUILD flow-tools-0.68-r8.ebuild 2789 RMD160 fbfc66ded64b75fcf8560566f2bec45af2642844 SHA1 df6c6c5f56ecae039b43ada510be7219cc8f0c11 SHA256 d862484357967ced06c2e006315810b5eb2b3369770afefd1357cfddd0c49ef7
EBUILD flow-tools-0.68.5-r1.ebuild 1703 RMD160 a4ed5173cff7ab7c64ed77d2c6fea5d838b47b39 SHA1 8564e73bee084c9d76b0846cced01e0fe5f9f496 SHA256 ed44d30536a8963fbace10007037b004567efa6e724e338c821308c37173639e
-MISC ChangeLog 9139 RMD160 770d7a544661916027b6d0d87d6602f08ea246e0 SHA1 340457d1298edb44f711ac1dd57b12b0d9067be7 SHA256 94afc7dfb1a4b284ad82c4f1fdbb61061ca13e86cc1aae07202c77233c9338d5
+EBUILD flow-tools-0.68.5.1.ebuild 1702 RMD160 ce8ed046082e82d30b556abaf3b9a62684bfa89a SHA1 d3502ce45d8b5ad95b0babbaef4c89f0f37b812b SHA256 d7b68c82c096b0e7d9e34dcf1bdcd1651be56b60e2c651e41216f6117cded4e2
+MISC ChangeLog 9680 RMD160 654afc781c72e16a9b7a128069b784215f22fb3c SHA1 e018587a480f672757fc16924fa46080199c0b17 SHA256 32dd67c2b4d1977e838f699610b8ed1cc1ecb9c0d610e0b3a2e820cef277b4d9
MISC metadata.xml 706 RMD160 48d179b230fd01a49853e73fc46f534373bb8488 SHA1 44ba0dd063806d48e8d6aa341c0bc28ea2d932b3 SHA256 4d947ce226ad090ea1274c75c6b360cb14ffdcd2f5730b0e596098aecb1b8daf
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v2.0.17 (GNU/Linux)
+
+iEYEARECAAYFAk7C3bUACgkQVWmRsqeSphNzVQCeM6AT2aIdP4D+cwYzGNlF8WEG
+zDEAnR6DKN/9418DDkQ6LX0bvr4y6Mt2
+=n+l6
+-----END PGP SIGNATURE-----
+++ /dev/null
-diff -urN flow-tools-0.67.orig/src/flow-export.c flow-tools-0.67/src/flow-export.c
---- flow-tools-0.67.orig/src/flow-export.c 2005-01-27 01:07:05.203972288 -0500
-+++ flow-tools-0.67/src/flow-export.c 2005-01-27 01:08:26.509611952 -0500
-@@ -937,6 +937,8 @@
- if (!res || PQresultStatus(res) != PGRES_COMMAND_OK) {
- PQclear(res);
- fterr_errx(1,"PQexec(): %s\n", PQerrorMessage(conn));
-+ } else if (res) {
-+ PQclear(res);
- }
-
- }
+++ /dev/null
-diff -urN flow-tools-0.67.orig/src/flow-export.c flow-tools-0.67/src/flow-export.c
---- flow-tools-0.67.orig/src/flow-export.c 2005-01-25 22:46:00.000000000 -0500
-+++ flow-tools-0.67/src/flow-export.c 2005-01-27 01:05:01.705746872 -0500
-@@ -758,10 +758,10 @@
- strcat (query, values);
- strcat (query, ")");
-
-- if (debug)
-+/* if (debug)
- fprintf(stderr, "field=%s\n val=%s\n query=%s\n", fields, values,
- query);
--
-+*/
- if (mysql_real_query(&mysql, query, strlen(query)) != 0)
- fterr_warnx("mysql_real_query(): %s", mysql_error(&mysql));
-
-@@ -929,10 +929,10 @@
- strcat (query, values);
- strcat (query, ")");
-
-- if (debug)
-+/* if (debug)
- fprintf(stderr, "field=%s\n val=%s\n query=%s\n", fields, values,
- query);
--
-+*/
- res = PQexec(conn, query);
- if (!res || PQresultStatus(res) != PGRES_COMMAND_OK) {
- PQclear(res);
+++ /dev/null
---- flow-tools-0.68/lib/ftlib.h.orig 2005-05-10 18:51:33.000000000 +0300
-+++ flow-tools-0.68/lib/ftlib.h 2009-09-21 17:36:37.000000000 +0300
-@@ -416,8 +416,8 @@
- };
-
- struct fttime {
-- u_int32 secs;
-- u_int32 msecs;
-+ time_t secs;
-+ time_t msecs;
- };
-
- struct ftver {
+++ /dev/null
-diff -Naur flow-tools-0.68.orig/lib/ftio.c flow-tools-0.68/lib/ftio.c
---- flow-tools-0.68.orig/lib/ftio.c 2007-05-15 18:56:54.000000000 +0000
-+++ flow-tools-0.68/lib/ftio.c 2007-05-15 18:48:02.000000000 +0000
-@@ -1605,6 +1605,7 @@
- u_int32 flags, fields;
- u_long period;
- int n, streaming2;
-+ time_t _ftime;
-
- fth = &ftio->fth;
-
-@@ -1639,17 +1640,21 @@
- }
-
- if (!streaming2)
-- if (fields & FT_FIELD_CAP_START)
-+ if (fields & FT_FIELD_CAP_START) {
-+ _ftime = (time_t)fth->cap_start;
- fprintf(std, "%c capture start: %s", cc,
-- ctime((time_t*)&fth->cap_start));
-+ ctime(&_ftime));
-+ }
-
- if (!streaming2) {
-
- if ((flags & FT_HEADER_FLAG_DONE) || (flags & FT_HEADER_FLAG_PRELOADED)) {
-
-- if (fields & FT_FIELD_CAP_END)
-+ if (fields & FT_FIELD_CAP_END) {
-+ _ftime = (time_t)fth->cap_end;
- fprintf(std, "%c capture end: %s", cc,
-- ctime((time_t*)&fth->cap_end));
-+ ctime(&_ftime));
-+ }
-
- period = fth->cap_end - fth->cap_start;
- if ((fields & FT_FIELD_CAP_END) && (fields & FT_FIELD_CAP_START))
-diff -Naur flow-tools-0.68.orig/lib/ftstat.c flow-tools-0.68/lib/ftstat.c
---- flow-tools-0.68.orig/lib/ftstat.c 2007-05-15 18:56:54.000000000 +0000
-+++ flow-tools-0.68/lib/ftstat.c 2007-05-15 18:51:00.000000000 +0000
-@@ -12363,7 +12363,7 @@
- {
- int comma, sort_field;
- char *buf, fmt_buf[32];
-- time_t now;
-+ time_t now, _ftime;
-
- /* shortcut */
- if (!(rpt->out->options & FT_STAT_OPT_HEADER))
-@@ -12619,11 +12619,13 @@
- fprintf(fp, "# records_shown: %s\n", fmt_buf);
- }
-
-+ _ftime = (time_t)rpt->time_start;
- fprintf(fp, "# first-flow: %lu %s",
-- (unsigned long)rpt->time_start, ctime((time_t*)&rpt->time_start));
-+ (unsigned long)rpt->time_start, ctime(&_ftime));
-
-+ _ftime = (time_t)rpt->time_end;
- fprintf(fp, "# last-flow: %lu %s",
-- (unsigned long)rpt->time_end, ctime((time_t*)&rpt->time_end));
-+ (unsigned long)rpt->time_end, ctime(&_ftime));
-
- now = time((time_t*)0L);
-
+++ /dev/null
-Patch by Rusnan R. Shaimardanov to fix bug #213788.
-
---- flow-tools-0.68/src/flow-export.c.orig 2009-05-26 02:41:15.000000000 +0200
-+++ flow-tools-0.68/src/flow-export.c 2009-05-26 02:54:56.000000000 +0200
-@@ -892,7 +892,7 @@
- db_name = strsep(&tmp, ":");
- db_table = strsep(&tmp, ":");
-
-- if (!db_user || !db_pwd || !db_host || !db_tmp || !db_name || !db_table) {
-+ if (!db_user || !db_pwd || !db_host || !db_port || !db_name || !db_table) {
- fterr_warnx("Missing field in dbaseURI, expecting user:pwd:host:port:name:table.");
- return -1;
- }
+++ /dev/null
-diff -Naur flow-tools-0.68.orig/lib/ftchash.c flow-tools-0.68/lib/ftchash.c
---- flow-tools-0.68.orig/lib/ftchash.c 2003-08-12 22:04:25.000000000 +0400
-+++ flow-tools-0.68/lib/ftchash.c 2006-09-06 22:42:12.000000000 +0400
-@@ -326,7 +326,7 @@
- (char*)ftch->traverse_chunk->base+ftch->traverse_chunk->next) {
-
- ret = ftch->traverse_rec;
-- (char*)ftch->traverse_rec += ftch->d_size;
-+ ftch->traverse_rec = ((char*)ftch->traverse_rec) + ftch->d_size;
- return ret;
-
- } else {
-diff -Naur flow-tools-0.68.orig/lib/ftfil.c flow-tools-0.68/lib/ftfil.c
---- flow-tools-0.68.orig/lib/ftfil.c 2004-01-05 20:55:23.000000000 +0300
-+++ flow-tools-0.68/lib/ftfil.c 2006-09-06 22:42:12.000000000 +0400
-@@ -2460,7 +2460,7 @@
- struct stat sb;
- struct jump *jmp;
- struct line_parser lp;
-- int fd, ret, found;
-+ int fd, ret, found = 0;
- char *buf, *buf2, *c;
- char sbuf[FT_LP_MAXLINE];
-
-@@ -2934,7 +2934,7 @@
- static int parse_definition_match(struct line_parser *lp, struct ftfil *ftfil)
- {
- struct ftfil_match_item *ftmi;
-- struct ftfil_match *ftm;
-+ struct ftfil_match *ftm = NULL;
- char *c;
-
- if (!lp->cur_def) {
-@@ -3057,7 +3057,7 @@
- struct ftfil_primitive *ftfp;
- struct ftfil_def *ftfd;
- int type, found, valid;
-- void *eval;
-+ void *eval = NULL;
-
- /* foreach definition */
- FT_SLIST_FOREACH(ftfd, &ftfil->defs, chain) {
-@@ -4984,7 +4984,7 @@
- char *p, *q, *r, c;
- int j, flag;
- unsigned i, i2;
-- int permit,deny;
-+ int permit = 0, deny = 0;
- u_int32 val;
-
- if (mode == FT_FIL_MODE_DENY) {
-diff -Naur flow-tools-0.68.orig/lib/ftfile.c flow-tools-0.68/lib/ftfile.c
---- flow-tools-0.68.orig/lib/ftfile.c 2003-02-13 05:38:42.000000000 +0300
-+++ flow-tools-0.68/lib/ftfile.c 2006-09-06 22:42:12.000000000 +0400
-@@ -417,12 +417,13 @@
- long gmt_val;
- char gmt_sign;
- int tm_gmtoff;
-+ time_t _ftime = (time_t)ftime;
-
-- if (!(tm = localtime ((time_t*)&ftime))) {
-+ if (!(tm = localtime (&_ftime))) {
- snprintf(buf, bsize, ".");
- }
-
-- tm_gmtoff = get_gmtoff(ftime);
-+ tm_gmtoff = get_gmtoff(_ftime);
-
- /* compute GMT offset */
- if (tm_gmtoff >= 0) {
-@@ -503,6 +504,7 @@
- {
- struct tm *tm;
- char buf[32];
-+ time_t _ftime = (time_t)ftime;
-
- /* no directories */
- if (nest == 0)
-@@ -512,7 +514,7 @@
- if ((nest > 3) || (nest < -3))
- return -1;
-
-- if (!(tm = localtime ((time_t*)&ftime)))
-+ if (!(tm = localtime (&_ftime)))
- return -1;
-
- if (nest == -1)
-diff -Naur flow-tools-0.68.orig/lib/ftio.c flow-tools-0.68/lib/ftio.c
---- flow-tools-0.68.orig/lib/ftio.c 2003-02-24 03:51:47.000000000 +0300
-+++ flow-tools-0.68/lib/ftio.c 2006-09-06 22:42:12.000000000 +0400
-@@ -2257,6 +2257,7 @@
- {
-
- int nleft, nread;
-+ char *p = ptr;
-
- nleft = nbytes;
- while (nleft > 0) {
-@@ -2267,7 +2268,7 @@
- break;
-
- nleft -= nread;
-- (char*)ptr += nread;
-+ p += nread;
- }
- return (nbytes - nleft);
- } /* readn */
-@@ -2284,6 +2285,7 @@
- {
-
- int nleft, nwritten;
-+ char *p = ptr;
-
- nleft = nbytes;
- while (nleft > 0) {
-@@ -2292,7 +2294,7 @@
- return(nwritten); /* error */
-
- nleft -= nwritten;
-- (char*)ptr += nwritten;
-+ p += nwritten;
- }
- return(nbytes - nleft);
- } /* writen */
-diff -Naur flow-tools-0.68.orig/lib/ftmask.c flow-tools-0.68/lib/ftmask.c
---- flow-tools-0.68.orig/lib/ftmask.c 2003-02-13 05:38:42.000000000 +0300
-+++ flow-tools-0.68/lib/ftmask.c 2006-09-06 22:42:12.000000000 +0400
-@@ -134,7 +134,7 @@
- struct stat sb;
- struct jump *jmp;
- struct line_parser lp;
-- int fd, ret, found;
-+ int fd, ret, found = 0;
- char *buf, *buf2, *c;
-
- ret = -1;
-diff -Naur flow-tools-0.68.orig/lib/ftstat.c flow-tools-0.68/lib/ftstat.c
---- flow-tools-0.68.orig/lib/ftstat.c 2005-05-10 19:48:12.000000000 +0400
-+++ flow-tools-0.68/lib/ftstat.c 2006-09-06 22:42:12.000000000 +0400
-@@ -151,7 +151,7 @@
- struct A *B;\
- struct tally tally;\
- char fmt_buf1[32], fmt_buf[1024];\
-- int len, fmt, sort_flags, sort_offset, comma;\
-+ int len, fmt, sort_flags, sort_offset = 0, comma;\
- fmt = FMT_JUST_LEFT;\
- fmt_buf1[0] = fmt_buf[0] = 0;\
- bzero(&tally, sizeof tally);\
-@@ -633,7 +633,7 @@
- struct fts3rec_all2 cur;\
- struct A *B;\
- u_int32 duration_tmp;\
-- double bps_tmp, pps_tmp;\
-+ double bps_tmp = 0, pps_tmp = 0;\
- B = rpt->data;\
- STD_ACCUM;
-
-@@ -664,7 +664,7 @@
- struct A *B;\
- u_int32 hash;\
- u_int32 duration_tmp;\
-- double bps_tmp, pps_tmp;\
-+ double bps_tmp = 0, pps_tmp = 0;\
- bzero(&D, sizeof D);\
- B = rpt->data;\
- STD_ACCUM;
-@@ -2732,7 +2732,7 @@
- struct stat sb;
- struct jump *jmp;
- struct line_parser lp;
-- int fd, ret, found;
-+ int fd, ret, found = 0;
- char *buf, *buf2, *c;
- char sbuf[FT_LP_MAXLINE];
-
-@@ -3214,7 +3214,7 @@
- struct ftstat_rpt_item *ftsrpti;
- struct ftstat_rpt_out *ftsro;
- int ret, noclose, pipe, status;
-- char fmt_tmp[64], fmt_buf[1024], path_buf[1024], *path_run;
-+ char fmt_tmp[64], fmt_buf[1024], path_buf[1024], *path_run = NULL;
- char *mode;
-
- noclose = 0; /* fclose fp */
-diff -Naur flow-tools-0.68.orig/lib/fttag.c flow-tools-0.68/lib/fttag.c
---- flow-tools-0.68.orig/lib/fttag.c 2004-01-05 20:55:37.000000000 +0300
-+++ flow-tools-0.68/lib/fttag.c 2006-09-06 22:42:12.000000000 +0400
-@@ -209,7 +209,7 @@
- struct stat sb;
- struct jump *jmp;
- struct line_parser lp;
-- int fd, ret, found;
-+ int fd, ret, found = 0;
- char *buf, *buf2, *c;
- char sbuf[FT_LP_MAXLINE];
-
-@@ -1477,7 +1477,7 @@
- struct fttag_def_term *ftdt;
- struct fttag_def_term_actions *ftdta;
- struct fttag_action *fta;
-- int i, found;
-+ int i, found = 0;
-
- /* foreach definition */
- FT_SLIST_FOREACH(ftd, &fttag->defs, chain) {
-diff -Naur flow-tools-0.68.orig/lib/fttlv.c flow-tools-0.68/lib/fttlv.c
---- flow-tools-0.68.orig/lib/fttlv.c 2003-02-13 05:38:43.000000000 +0300
-+++ flow-tools-0.68/lib/fttlv.c 2006-09-06 22:42:12.000000000 +0400
-@@ -55,6 +55,7 @@
- int fttlv_enc_uint32(void *buf, int buf_size, int flip, u_int16 t, u_int32 v)
- {
- u_int16 len;
-+ char *p = buf;
-
- if (buf_size < 8)
- return -1;
-@@ -67,13 +68,13 @@
- SWAPINT32(v);
- }
-
-- bcopy(&t, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&t, p, 2);
-+ p += 2;
-
-- bcopy(&len, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&len, p, 2);
-+ p += 2;
-
-- bcopy(&v, buf, 4);
-+ bcopy(&v, p, 4);
-
- return 8;
-
-@@ -94,6 +95,7 @@
- int fttlv_enc_uint16(void *buf, int buf_size, int flip, u_int16 t, u_int16 v)
- {
- u_int16 len;
-+ char *p = buf;
-
- if (buf_size < 6)
- return -1;
-@@ -106,13 +108,13 @@
- SWAPINT16(v);
- }
-
-- bcopy(&t, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&t, p, 2);
-+ p += 2;
-
-- bcopy(&len, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&len, p, 2);
-+ p += 2;
-
-- bcopy(&v, buf, 2);
-+ bcopy(&v, p, 2);
-
- return 6;
-
-@@ -133,6 +135,7 @@
- int fttlv_enc_uint8(void *buf, int buf_size, int flip, u_int16 t, u_int8 v)
- {
- u_int16 len;
-+ char *p = buf;
-
- if (buf_size < 5)
- return -1;
-@@ -144,13 +147,13 @@
- SWAPINT16(len);
- }
-
-- bcopy(&t, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&t, p, 2);
-+ p += 2;
-
-- bcopy(&len, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&len, p, 2);
-+ p += 2;
-
-- bcopy(&v, buf, 1);
-+ bcopy(&v, p, 1);
-
- return 5;
-
-@@ -171,7 +174,8 @@
- int fttlv_enc_str(void *buf, int buf_size, int flip, u_int16 t, char *v)
- {
- u_int16 len, len2;
--
-+ char *p = buf;
-+
- len = len2 = strlen(v)+1;
-
- if (buf_size < 4+len)
-@@ -182,13 +186,13 @@
- SWAPINT16(len);
- }
-
-- bcopy(&t, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&t, p, 2);
-+ p += 2;
-
-- bcopy(&len, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&len, p, 2);
-+ p += 2;
-
-- bcopy(v, buf, len);
-+ bcopy(v, p, len);
-
- return 4+len2;
-
-@@ -214,7 +218,8 @@
- {
- u_int16 len, len2;
- int n;
--
-+ char *p = buf;
-+
- n = strlen(name)+1;
-
- len = len2 = n+2+4;
-@@ -229,19 +234,19 @@
- if (buf_size < 4+len)
- return -1;
-
-- bcopy(&t, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&t, p, 2);
-+ p += 2;
-
-- bcopy(&len, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&len, p, 2);
-+ p += 2;
-
-- bcopy(&ip, buf, 4);
-- (char*)buf += 4;
-+ bcopy(&ip, p, 4);
-+ p += 4;
-
-- bcopy(&ifIndex, buf, 2);
-- (char*)buf += 2;
-+ bcopy(&ifIndex, p, 2);
-+ p += 2;
-
-- bcopy(name, buf, n);
-+ bcopy(name, p, n);
-
- return 4+len2;
-
-@@ -267,6 +272,7 @@
- {
- u_int16 len, len2;
- int n,i,esize;
-+ char *p = buf;
-
- n = strlen(name)+1;
- esize = (entries*2);
-@@ -286,22 +292,22 @@
- SWAPINT16(entries);
- }
-
-- bcopy(&t, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&t, p, 2);
-+ p += 2;
-
-- bcopy(&len, buf, 2);
-- (char*)buf+= 2;
-+ bcopy(&len, p, 2);
-+ p += 2;
-
-- bcopy(&ip, buf, 4);
-- (char*)buf += 4;
-+ bcopy(&ip, p, 4);
-+ p += 4;
-
-- bcopy(&entries, buf, 2);
-- (char*)buf += 2;
-+ bcopy(&entries, p, 2);
-+ p += 2;
-
-- bcopy(ifIndex_list, buf, esize);
-- (char*)buf += esize;
-+ bcopy(ifIndex_list, p, esize);
-+ p += esize;
-
-- bcopy(name, buf, n);
-+ bcopy(name, p, n);
-
- return 4+len2;
-
-diff -Naur flow-tools-0.68.orig/lib/ftxlate.c flow-tools-0.68/lib/ftxlate.c
---- flow-tools-0.68.orig/lib/ftxlate.c 2005-05-11 18:03:30.000000000 +0400
-+++ flow-tools-0.68/lib/ftxlate.c 2006-09-06 22:42:12.000000000 +0400
-@@ -297,7 +297,7 @@
- struct stat sb;
- struct jump *jmp;
- struct line_parser lp;
-- int fd, ret, found;
-+ int fd, ret, found = 0;
- char *buf, *buf2, *c;
- char sbuf[FT_LP_MAXLINE];
-
-@@ -1504,7 +1504,7 @@
- struct ftxlate_def_term_actions *ftxta;
- struct ftxlate_action *ftxa;
- struct ftxlate_act_ip_addr_anon *ftxiaa;
-- int i, found;
-+ int i, found = 0;
-
- /* foreach action do any additional initialization */
- FT_SLIST_FOREACH(ftxa, &ftxlate->actions, chain) {
-diff -Naur flow-tools-0.68.orig/lib/radix.c flow-tools-0.68/lib/radix.c
---- flow-tools-0.68.orig/lib/radix.c 2003-02-13 05:05:25.000000000 +0300
-+++ flow-tools-0.68/lib/radix.c 2006-09-06 22:42:12.000000000 +0400
-@@ -902,6 +902,7 @@
- rn_init(void)
- {
- char *cp, *cplim;
-+ void **p = (void **)&mask_rnhead;
- if (max_keylen == 0) {
- printf("rn_init: radix functions require max_keylen be set\n");
- return;
-@@ -912,7 +913,7 @@
- addmask_key = cplim = rn_ones + max_keylen;
- while (cp < cplim)
- *cp++ = -1;
-- if (rn_inithead((void **)&mask_rnhead, 0) == 0)
-+ if (rn_inithead(p, 0) == 0)
- panic("rn_init 2");
- }
-
-diff -Naur flow-tools-0.68.orig/lib/support.c flow-tools-0.68/lib/support.c
---- flow-tools-0.68.orig/lib/support.c 2003-02-13 05:38:43.000000000 +0300
-+++ flow-tools-0.68/lib/support.c 2006-09-06 22:42:12.000000000 +0400
-@@ -286,7 +286,7 @@
- struct in_addr *ina;
- u_long addr = 0;
- u_int n;
-- int dns, shift;
-+ int dns, shift = 0;
- char *t;
-
- /* if there is anything ascii in here, this may be a hostname */
-@@ -627,6 +627,8 @@
- {
- char *c, *cs, *c2, *p, *p2;
- int len, ret, done, nodir;
-+
-+ c = cs = c2 = p = p2 = NULL;
-
- len = strlen(path);
- c = (char*)0L;
-diff -Naur flow-tools-0.68.orig/src/flow-capture.c flow-tools-0.68/src/flow-capture.c
---- flow-tools-0.68.orig/src/flow-capture.c 2004-01-05 20:56:50.000000000 +0300
-+++ flow-tools-0.68/src/flow-capture.c 2006-09-06 22:42:12.000000000 +0400
-@@ -145,7 +145,7 @@
- struct ftpeeri ftpi;
- struct ftver ftv;
- struct ftchash *ftch;
-- struct ftchash_rec_exp ftch_recexp, *ftch_recexpp;
-+ struct ftchash_rec_exp ftch_recexp, *ftch_recexpp = NULL;
- struct rotate rot;
- struct file cap_file;
- struct fttag fttag;
-diff -Naur flow-tools-0.68.orig/src/flow-cat.c flow-tools-0.68/src/flow-cat.c
---- flow-tools-0.68.orig/src/flow-cat.c 2005-05-10 19:52:10.000000000 +0400
-+++ flow-tools-0.68/src/flow-cat.c 2006-09-06 22:42:12.000000000 +0400
-@@ -65,14 +65,14 @@
- struct ftset ftset;
- struct ftfile_entries **fte;
- struct ftfile_entry *fty;
-- int i, out_fd, out_fd_plain, in_fd, disable_mmap, in_fd_plain, sort;
-+ int i, out_fd, out_fd_plain, in_fd, disable_mmap, in_fd_plain = 0, sort;
- int fields;
- int x, n, fd, flags, fte_entries, preload, time_filter;
- char *fname, *out_fname;
- char *rec;
- u_long total_bytes;
- u_int32 total_flows, lost_flows, corrupt_flows, total_streams;
-- u_int32 time_start, time_end, time_tmp1, time_tmp2, time_delta;
-+ u_int32 time_start, time_end, time_tmp1 = 0, time_tmp2 = 0, time_delta;
- u_int32 time_low, time_high;
-
- /* init fterr */
-diff -Naur flow-tools-0.68.orig/src/flow-dscan.c flow-tools-0.68/src/flow-dscan.c
---- flow-tools-0.68.orig/src/flow-dscan.c 2005-05-10 19:53:11.000000000 +0400
-+++ flow-tools-0.68/src/flow-dscan.c 2006-09-06 22:42:12.000000000 +0400
-@@ -618,8 +618,8 @@
- {
- FILE *FP;
- int done;
-- struct dscan_rec *drp;
-- struct dscan_dst *ddp;
-+ struct dscan_rec *drp = NULL;
-+ struct dscan_dst *ddp = NULL;
- char type;
- char buf[1024];
- u_int32 ip, hash, depth, flags, h, time, nports, i, j;
-diff -Naur flow-tools-0.68.orig/src/flow-export.c flow-tools-0.68/src/flow-export.c
---- flow-tools-0.68.orig/src/flow-export.c 2004-03-31 07:11:14.000000000 +0400
-+++ flow-tools-0.68/src/flow-export.c 2006-09-06 22:42:12.000000000 +0400
-@@ -865,7 +865,7 @@
- struct ftver ftv;
- char fields[1024], values[1024], query[3*1024];
- char *rec;
-- char *db_host, *db_name, *db_table, *db_user, *db_pwd, *db_tmp, *tmp;
-+ char *db_host, *db_name, *db_table, *db_user, *db_pwd, *db_tmp = NULL, *tmp;
- char *db_port;
- int len;
-
-@@ -961,7 +961,7 @@
-
- int fmt_xfields_type(char *buf, u_int64 xfield)
- {
-- int comma;
-+ int comma = 0;
-
- buf[0] = 0;
-
-diff -Naur flow-tools-0.68.orig/src/flow-fanout.c flow-tools-0.68/src/flow-fanout.c
---- flow-tools-0.68.orig/src/flow-fanout.c 2005-05-10 19:52:52.000000000 +0400
-+++ flow-tools-0.68/src/flow-fanout.c 2006-09-06 22:42:12.000000000 +0400
-@@ -100,8 +100,8 @@
- struct tm *tm;
- time_t now, time_startup;
- fd_set rfd;
-- struct ip *ip_hdr;
-- struct udphdr *udp_hdr;
-+ struct ip *ip_hdr = NULL;
-+ struct udphdr *udp_hdr = NULL;
- struct ftpeeri ftpi;
- struct ftpdu ftpdu;
- struct ftver ftv;
-diff -Naur flow-tools-0.68.orig/src/flow-filter.c flow-tools-0.68/src/flow-filter.c
---- flow-tools-0.68.orig/src/flow-filter.c 2004-11-03 05:06:35.000000000 +0300
-+++ flow-tools-0.68/src/flow-filter.c 2006-09-06 22:42:12.000000000 +0400
-@@ -75,15 +75,15 @@
- struct ftset ftset;
- struct ftver ftv;
- struct ftprof ftp;
-- u_int32 time_start, time_end, exaddr;
-+ u_int32 time_start, time_end, exaddr = 0;
- int i, ret;
- char *acl_fname, *acl_std_src_name, *acl_std_dst_name;
- char *acl_std_nexthop_name;
- char *acl_ext_name, *str, *strm;
-- int acl_std_src_index, acl_std_src_index2;
-- int acl_std_dst_index, acl_std_dst_index2;
-- int acl_std_nexthop_index, acl_std_nexthop_index2;
-- int acl_ext_index, acl_ext_index2;
-+ int acl_std_src_index, acl_std_src_index2 = 0;
-+ int acl_std_dst_index, acl_std_dst_index2 = 0;
-+ int acl_std_nexthop_index, acl_std_nexthop_index2 = 0;
-+ int acl_ext_index, acl_ext_index2 = 0;
- struct acl_ip_ext_entry tmp_ext;
- int keep_input_time;
- int filter_input, filter_output, filter_srcport, filter_dstport;
-diff -Naur flow-tools-0.68.orig/src/flow-import.c flow-tools-0.68/src/flow-import.c
---- flow-tools-0.68.orig/src/flow-import.c 2003-11-11 19:53:57.000000000 +0300
-+++ flow-tools-0.68/src/flow-import.c 2006-09-06 22:42:12.000000000 +0400
-@@ -1060,9 +1060,9 @@
- struct ftpdu_header ftheader, ftheader2;
- struct ftpdu ftpdu;
- struct ftseq ftseq;
-- size_t rlen, len;
-+ size_t rlen, len = 0;
- void (*xlate)(void *in_rec, void *out_rec);
-- int ret, n, i, offset;
-+ int ret = 0, n, i, offset;
- char xl_rec[FT_IO_MAXREC], *out_rec;
-
- bzero (&ftpdu, sizeof ftpdu);
-diff -Naur flow-tools-0.68.orig/src/flow-mask.c flow-tools-0.68/src/flow-mask.c
---- flow-tools-0.68.orig/src/flow-mask.c 2003-04-02 22:03:02.000000000 +0400
-+++ flow-tools-0.68/src/flow-mask.c 2006-09-06 22:42:12.000000000 +0400
-@@ -59,7 +59,7 @@
- struct fts3rec_offsets fo;
- char *rec;
- char *fname, *dname;
-- u_int32 total_flows, cap_start, cap_end;
-+ u_int32 total_flows, cap_start = 0, cap_end = 0;
- u_int32 time_start, time_end;
- int i, keep_input_time;
-
-diff -Naur flow-tools-0.68.orig/src/flow-nfilter.c flow-tools-0.68/src/flow-nfilter.c
---- flow-tools-0.68.orig/src/flow-nfilter.c 2004-01-05 20:57:18.000000000 +0300
-+++ flow-tools-0.68/src/flow-nfilter.c 2006-09-06 22:42:12.000000000 +0400
-@@ -60,7 +60,7 @@
- struct ftvar ftvar;
- char *rec;
- char *fname, *dname;
-- u_int32 total_flows, cap_start, cap_end;
-+ u_int32 total_flows, cap_start = 0, cap_end = 0;
- u_int32 time_start, time_end;
- int i, keep_input_time;
-
-diff -Naur flow-tools-0.68.orig/src/flow-print.c flow-tools-0.68/src/flow-print.c
---- flow-tools-0.68.orig/src/flow-print.c 2003-04-02 22:03:02.000000000 +0400
-+++ flow-tools-0.68/src/flow-print.c 2006-09-06 22:42:12.000000000 +0400
-@@ -96,7 +96,7 @@
- {
- struct ftio ftio;
- struct ftprof ftp;
-- int i, format_index, set_format, ret;
-+ int i, format_index = 0, set_format, ret;
- int print_header, options, debug;
- char cc; /* comment character */
-
-diff -Naur flow-tools-0.68.orig/src/flow-send.c flow-tools-0.68/src/flow-send.c
---- flow-tools-0.68.orig/src/flow-send.c 2004-03-31 07:15:41.000000000 +0400
-+++ flow-tools-0.68/src/flow-send.c 2006-09-06 22:42:12.000000000 +0400
-@@ -63,8 +63,8 @@
- int main(int argc, char **argv)
- {
- struct sockaddr_in loc_addr, rem_addr;
-- struct ip *ip_hdr;
-- struct udphdr *udp_hdr;
-+ struct ip *ip_hdr = NULL;
-+ struct udphdr *udp_hdr = NULL;
- struct ftio ftio;
- struct ftprof ftp;
- struct ftver ftv, ftv2;
-@@ -75,8 +75,8 @@
- char xl_rec[FT_IO_MAXREC], *out_rec;
- u_int32 privacy_mask;
- unsigned int v1, v2, one;
-- int i, n, ret, tx_delay, udp_sock;
-- int src_ip_spoof, hdr_len;
-+ int i, n, ret = 0, tx_delay, udp_sock;
-+ int src_ip_spoof, hdr_len = 0;
- void *rec;
-
- /* init fterr */
-diff -Naur flow-tools-0.68.orig/src/flow-stat.c flow-tools-0.68/src/flow-stat.c
---- flow-tools-0.68.orig/src/flow-stat.c 2004-11-03 05:12:36.000000000 +0300
-+++ flow-tools-0.68/src/flow-stat.c 2006-09-06 22:42:12.000000000 +0400
-@@ -3575,7 +3575,7 @@
- char fmt_buf[256], fmt_buf2[64];
- int32 i, start, end, increment, x;
- int s, len;
-- u_int plines;
-+ u_int plines = 0;
- u_int32 *index;
-
- s = abs(args->sort_order);
-diff -Naur flow-tools-0.68.orig/src/flow-tag.c flow-tools-0.68/src/flow-tag.c
---- flow-tools-0.68.orig/src/flow-tag.c 2004-01-05 21:00:40.000000000 +0300
-+++ flow-tools-0.68/src/flow-tag.c 2006-09-06 22:42:12.000000000 +0400
-@@ -60,7 +60,7 @@
- struct fttag_def *ftd;
- struct ftvar ftvar;
- int i, keep_input_time;
-- u_int32 total_flows, cap_start, cap_end;
-+ u_int32 total_flows, cap_start = 0, cap_end = 0;
- u_int32 time_start, time_end;
- char *tag_defs, *tag_active;
- char *rec_in, *rec_out;
-diff -Naur flow-tools-0.68.orig/src/flow-xlate.c flow-tools-0.68/src/flow-xlate.c
---- flow-tools-0.68.orig/src/flow-xlate.c 2004-01-05 21:00:40.000000000 +0300
-+++ flow-tools-0.68/src/flow-xlate.c 2006-09-06 22:42:12.000000000 +0400
-@@ -53,7 +53,7 @@
- struct ftio ftio_in, ftio_out;
- struct ftprof ftp;
- struct ftxlate ftxlate;
-- struct ftxlate_def *ftfd;
-+ struct ftxlate_def *ftfd = NULL;
- struct ftver ftv_in, ftv_out;
- struct ftset ftset;
- struct fts3rec_offsets fo;
-@@ -61,7 +61,7 @@
- char *rec, out_rec[FT_IO_MAXREC];
- char *fname, *dname;
- unsigned int v1, v2;
-- u_int32 total_flows, cap_start, cap_end;
-+ u_int32 total_flows, cap_start = 0, cap_end = 0;
- u_int32 time_start, time_end;
- int i, n, keep_input_time;
- int xlate_version;
+++ /dev/null
-diff --exclude='*~' --exclude='.*' -I '$Id:' -urN flow-tools-0.68.orig/acconfig.h flow-tools-0.68/acconfig.h
---- flow-tools-0.68.orig/acconfig.h 2005-05-05 23:31:14.000000000 -0400
-+++ flow-tools-0.68/acconfig.h 1969-12-31 19:00:00.000000000 -0500
-@@ -1,28 +0,0 @@
--
--/* Name of package. */
--#undef PACKAGE
--
--/* Version of package. */
--#undef VERSION
--
--/* Linux */
--#undef _BSD_SOURCE
--
--/* Linux */
--#undef HAVE_FEATURES_H
--
--/* BSD socket */
--#undef HAVE_SOCK_SIN_LEN
--
--/* MYSQL */
--#undef HAVE_MYSQL
--
--/* PGSQL */
--#undef HAVE_PGSQL
--
--/* DEC */
--#undef HAVE_LL_STRTOUL
--
--/* OPENSSL */
--#undef HAVE_OPENSSL
--
-diff --exclude='*~' --exclude='.*' -I '$Id:' -urN flow-tools-0.68.orig/configure.in flow-tools-0.68/configure.in
---- flow-tools-0.68.orig/configure.in 2005-05-11 10:15:48.000000000 -0400
-+++ flow-tools-0.68/configure.in 2005-05-13 23:47:20.000000000 -0400
-@@ -28,77 +28,57 @@
- AC_SUBST(OPENSSLINCLUDE)
-
- dnl extra argument: --with-mysql
--WITH_MYSQL=
- AC_ARG_WITH(mysql,
--[ --with-mysql[=PATH] Compile in MySQL support. (default=no)],
--[ if test -x "$withval"; then
-- WHERE_MYSQL=$withval
-- else
-- WHERE_MYSQL="/usr"
-- fi
--]
--)
-+ [ --with-mysql Compile in MySQL support (default=no)],
-+ [ac_with_mysql=$withval],
-+ [ac_with_mysql=no])
-+
-+if test x$ac_with_mysql = xyes ; then
-+ LIBS="-L/usr/lib/mysql"
-+ AC_CHECK_LIB(mysqlclient, my_init,
-+ [
-+ MYSQLCFLAGS="-L/usr/lib/mysql -I/usr/include/mysql"
-+ MYSQLLIB="-lmysqlclient"
-+ AC_DEFINE([HAVE_MYSQL], 1, [Compile MySQL support])
-+ ]
-+ )
-+fi
-
- dnl extra argument: --with-pgsql
--WITH_PGSQL=
- AC_ARG_WITH(pgsql,
--[ --with-pgsql[=PATH] Compile in PostgreSQL support. (default=no)],
--[ if test -x "$withval"; then
-- WHERE_PGSQL=$withval
-- else
-- WHERE_PGSQL="/usr"
-- fi
--]
--)
-+ [ --with-pgsql Compile in PostgreSQL support (default=no)],
-+ [ac_with_pgsql=$withval],
-+ [ac_with_pgsql=no])
-+
-+if test x$ac_with_pgsql = xyes ; then
-+ LIBS="-L/usr/lib/postgresql"
-+ AC_CHECK_LIB(pq, PQsetdbLogin,
-+ [
-+ PGSQLCFLAGS="-L/usr/lib/postgresql -I/usr/include/postgresql"
-+ PGSQLLIB="-lpq"
-+ AC_DEFINE([HAVE_PGSQL], 1, [Compile PostgreSQL support])
-+ ]
-+ )
-+fi
-
- dnl extra argument: --with-openssl
--WITH_OPENSSL=
- AC_ARG_WITH(openssl,
--[ --with-openssl[=PATH] Compile in OpenSSL support. (default=no)],
--[ if test -x "$withval"; then
-- WHERE_OPENSSL=$withval
-- else
-- WHERE_OPENSSL="/usr"
-- fi
--]
--)
--
--dnl Checks for libraries.
-+ [ --with-openssl Compile in OpenSSL support (default=no)],
-+ [ac_with_openssl=$withval],
-+ [ac_with_openssl=no])
-
--if test "x$WHERE_MYSQL" != "x"; then
-- LIBS="-L$WHERE_MYSQL/lib/mysql"
-- AC_CHECK_LIB(mysqlclient, my_init,
-- [
-- MYSQLCFLAGS="-L$WHERE_MYSQL/lib/mysql -I$WHERE_MYSQL/include/mysql"
-- MYSQLLIB="-lmysqlclient"
-- AC_DEFINE(HAVE_MYSQL)
-- ]
-- )
--fi
--
--if test "x$WHERE_OPENSSL" != "x"; then
-- LIBS="-L$WHERE_OPENSSL/lib"
-+if test x$ac_with_openssl = xyes ; then
-+ LIBS="-L/usr/lib"
- AC_CHECK_LIB(crypto, EVP_EncryptUpdate,
- [
-- OPENSSLCFLAGS="-L$WHERE_OPENSSL/lib -I$WHERE_OPENSSL/include"
-+ OPENSSLCFLAGS="-L/usr/lib -I/usr/include"
- CRYPTOLIB="-lcrypto"
-- AC_DEFINE(HAVE_OPENSSL)
-- ]
-- )
--fi
--
--
--if test "x$WHERE_PGSQL" != "x"; then
-- LIBS="-L$WHERE_PGSQL/lib/pgsql"
-- AC_CHECK_LIB(pq, PQsetdbLogin,
-- [
-- PGSQLCFLAGS="-L$WHERE_PGSQL/lib -I$WHERE_PGSQL/include/pgsql"
-- PGSQLLIB="-lpq"
-- AC_DEFINE(HAVE_PGSQL)
-+ AC_DEFINE([HAVE_OPENSSL], 1, [Compile OpenSSL support])
- ]
- )
- fi
-
-+dnl Checks for libraries.
- AC_CHECK_LIB(y, main,YLIB="$YLIB -ly",)
- AC_CHECK_LIB(z, zlibVersion)
- case "X$LIBS" in
-@@ -121,11 +101,11 @@
- #include <sys/socket.h>
- #include <netinet/in.h>],
- [struct sockaddr_in sock; sock.sin_len = sizeof(sock);],
--echo yes;AC_DEFINE(HAVE_SOCK_SIN_LEN),
-+echo yes;AC_DEFINE([HAVE_SOCK_SIN_LEN], 1, [Define if sockaddr_in.sin_len member exists]),
- echo no)
-
-
--AC_DEFINE(_BSD_SOURCE)
-+AC_DEFINE([_BSD_SOURCE], 1, [Define BSD source])
-
- dnl Checks for typedefs, structures, and compiler characteristics.
- AC_C_CONST
-@@ -162,7 +142,7 @@
- }
- ],
- [AC_MSG_RESULT(yes)
-- AC_DEFINE(HAVE_LL_STRTOUL)
-+ AC_DEFINE([HAVE_LL_STRTOUL], 1, [Define if strtoul returns 64 bits])
- ],
- [AC_MSG_RESULT(no)],
- )
+++ /dev/null
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/flow-tools/flow-tools-0.68-r5.ebuild,v 1.9 2010/12/18 12:43:47 armin76 Exp $
-
-WANT_AUTOMAKE="1.6"
-WANT_AUTOCONF="latest"
-inherit eutils flag-o-matic autotools
-
-DESCRIPTION="Flow-tools is a package for collecting and processing NetFlow data"
-HOMEPAGE="http://www.splintered.net/sw/flow-tools/"
-SRC_URI="ftp://ftp.eng.oar.net/pub/flow-tools/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="amd64 ppc x86"
-IUSE="mysql postgres debug ssl"
-
-RDEPEND="sys-apps/tcp-wrappers
- sys-libs/zlib
- !postgres? ( mysql? ( virtual/mysql ) )
- !mysql? ( postgres? ( dev-db/postgresql-server ) )
- ssl? ( dev-libs/openssl )"
-
-DEPEND="${RDEPEND}
- sys-devel/flex
- sys-devel/bison"
-
-pkg_setup() {
- if use mysql && use postgres ; then
- echo
- eerror "The mysql and postgres USE flags are mutually exclusive."
- eerror "Please choose either USE=mysql or USE=postgres, but not both."
- die
- fi
-
- enewgroup flows
- enewuser flows -1 -1 /var/lib/flows flows
-}
-
-src_unpack() {
- unpack ${A}
- cd "${S}"
- epatch "${FILESDIR}"/${P}-fix-configure.diff
- epatch "${FILESDIR}"/${P}-fix-a-zillion-warnings-updated.diff
- epatch "${FILESDIR}"/${P}-another-amd64-casting-fixes.patch
- use debug || epatch "${FILESDIR}"/${PN}-0.67-nodebug.patch
- epatch "${FILESDIR}"/${PN}-0.67-memleak.patch
-
- sed -i "s|^[^#]\(^.*CFLAGS=\).*$|\1-Wall|g" \
- configure.in src/Makefile.am lib/Makefile.am || die "sed CFLAGS failed"
-
- # bug 122842, we have /usr/bin/python and not /usr/local/bin/python
- sed -i -e "s:/usr/local/bin/python:/usr/bin/python:g" \
- "${S}"/bin/flow-{rptfmt,rpt2rrd,log2rrd}
-
- AM_OPTS="-f -i"
- eautoreconf || die "autoreconf failed"
-}
-
-src_compile() {
- use mysql && append-flags "-L/usr/lib/mysql -I/usr/include/mysql"
- use postgres && append-flags "-L/usr/lib/postgres -I/usr/include/postgres"
-
- econf \
- --localstatedir=/etc/flow-tools \
- --enable-lfs \
- $(use_with ssl openssl) \
- $(use_with mysql) \
- $(use_with postgres pgsql) \
- || die "econf failed"
-
- emake CFLAGS="${CFLAGS}" || die "emake failed"
-}
-
-src_install() {
- make DESTDIR="${D}" install || die "make install failed"
- dodoc ChangeLog README SECURITY TODO
-
- keepdir /var/lib/flows
- keepdir /var/lib/flows/bin
- exeinto /var/lib/flows/bin
- doexe "${FILESDIR}"/linkme
- keepdir /var/run/flows
-
- newinitd "${FILESDIR}/flowcapture.initd" flowcapture
- newconfd "${FILESDIR}/flowcapture.confd" flowcapture
-
-}
-
-pkg_postinst() {
- chown flows:flows /var/run/flows
- chown flows:flows /var/lib/flows
- chown flows:flows /var/lib/flows/bin
- chmod 0755 /var/run/flows
- chmod 0755 /var/lib/flows
- chmod 0755 /var/lib/flows/bin
-}
+++ /dev/null
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/flow-tools/flow-tools-0.68-r7.ebuild,v 1.4 2010/12/18 12:43:47 armin76 Exp $
-
-WANT_AUTOMAKE="1.6"
-WANT_AUTOCONF="latest"
-inherit eutils flag-o-matic autotools
-
-DESCRIPTION="Flow-tools is a package for collecting and processing NetFlow data"
-HOMEPAGE="http://www.splintered.net/sw/flow-tools/"
-SRC_URI="ftp://ftp.eng.oar.net/pub/flow-tools/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="~amd64 ~ppc ~x86"
-IUSE="mysql postgres debug ssl"
-
-RDEPEND="sys-apps/tcp-wrappers
- sys-libs/zlib
- !postgres? ( mysql? ( virtual/mysql ) )
- !mysql? ( postgres? ( dev-db/postgresql-server ) )
- ssl? ( dev-libs/openssl )"
-
-DEPEND="${RDEPEND}
- sys-devel/flex
- sys-devel/bison"
-
-pkg_setup() {
- if use mysql && use postgres ; then
- echo
- eerror "The mysql and postgres USE flags are mutually exclusive."
- eerror "Please choose either USE=mysql or USE=postgres, but not both."
- die
- fi
-
- enewgroup flows
- enewuser flows -1 -1 /var/lib/flows flows
-}
-
-src_unpack() {
- unpack ${A}
- cd "${S}"
- epatch "${FILESDIR}"/${P}-fix-configure.diff
- epatch "${FILESDIR}"/${P}-fix-a-zillion-warnings-updated.diff
- epatch "${FILESDIR}"/${P}-another-amd64-casting-fixes.patch
- use debug || epatch "${FILESDIR}"/${PN}-0.67-nodebug.patch
- epatch "${FILESDIR}"/${PN}-0.67-memleak.patch
- epatch "${FILESDIR}"/${P}-db_tmp.patch
-
- sed -i "s|^[^#]\(^.*CFLAGS=\).*$|\1-Wall|g" \
- configure.in src/Makefile.am lib/Makefile.am || die "sed CFLAGS failed"
-
- # bug 122842, we have /usr/bin/python and not /usr/local/bin/python
- sed -i -e "s:/usr/local/bin/python:/usr/bin/python:g" \
- "${S}"/bin/flow-{rptfmt,rpt2rrd,log2rrd}
-
- AM_OPTS="-f -i"
- eautoreconf || die "autoreconf failed"
-}
-
-src_compile() {
- use mysql && append-flags "-L/usr/lib/mysql -I/usr/include/mysql"
- use postgres && append-flags "-L/usr/lib/postgres -I/usr/include/postgres"
-
- econf \
- --localstatedir=/etc/flow-tools \
- --enable-lfs \
- $(use_with ssl openssl) \
- $(use_with mysql) \
- $(use_with postgres pgsql) \
- || die "econf failed"
-
- emake CFLAGS="${CFLAGS}" || die "emake failed"
-}
-
-src_install() {
- make DESTDIR="${D}" install || die "make install failed"
- dodoc ChangeLog README SECURITY TODO
-
- keepdir /var/lib/flows
- keepdir /var/lib/flows/bin
- exeinto /var/lib/flows/bin
- doexe "${FILESDIR}"/linkme
- keepdir /var/run/flows
-
- newinitd "${FILESDIR}/flowcapture.initd" flowcapture
- newconfd "${FILESDIR}/flowcapture.confd" flowcapture
-
-}
-
-pkg_postinst() {
- chown flows:flows /var/run/flows
- chown flows:flows /var/lib/flows
- chown flows:flows /var/lib/flows/bin
- chmod 0755 /var/run/flows
- chmod 0755 /var/lib/flows
- chmod 0755 /var/lib/flows/bin
-}
+++ /dev/null
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/flow-tools/flow-tools-0.68-r8.ebuild,v 1.4 2010/12/18 12:43:47 armin76 Exp $
-
-WANT_AUTOMAKE="1.6"
-WANT_AUTOCONF="latest"
-inherit eutils flag-o-matic autotools
-
-DESCRIPTION="Flow-tools is a package for collecting and processing NetFlow data"
-HOMEPAGE="http://www.splintered.net/sw/flow-tools/"
-SRC_URI="ftp://ftp.eng.oar.net/pub/flow-tools/${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0"
-KEYWORDS="~amd64 ~ppc ~x86"
-IUSE="mysql postgres debug ssl"
-
-RDEPEND="sys-apps/tcp-wrappers
- sys-libs/zlib
- !postgres? ( mysql? ( virtual/mysql ) )
- !mysql? ( postgres? ( dev-db/postgresql-server ) )
- ssl? ( dev-libs/openssl )"
-
-DEPEND="${RDEPEND}
- sys-devel/flex
- sys-devel/bison"
-
-pkg_setup() {
- if use mysql && use postgres ; then
- echo
- eerror "The mysql and postgres USE flags are mutually exclusive."
- eerror "Please choose either USE=mysql or USE=postgres, but not both."
- die
- fi
-
- enewgroup flows
- enewuser flows -1 -1 /var/lib/flows flows
-}
-
-src_unpack() {
- unpack ${A}
- cd "${S}"
- epatch "${FILESDIR}"/${P}-fix-configure.diff
- epatch "${FILESDIR}"/${P}-fix-a-zillion-warnings-updated.diff
- epatch "${FILESDIR}"/${P}-another-amd64-casting-fixes.patch
- epatch "${FILESDIR}"/${P}-249449-amd64.patch
- use debug || epatch "${FILESDIR}"/${PN}-0.67-nodebug.patch
- epatch "${FILESDIR}"/${PN}-0.67-memleak.patch
- epatch "${FILESDIR}"/${P}-db_tmp.patch
-
- sed -i "s|^[^#]\(^.*CFLAGS=\).*$|\1-Wall|g" \
- configure.in src/Makefile.am lib/Makefile.am || die "sed CFLAGS failed"
-
- # bug 122842, we have /usr/bin/python and not /usr/local/bin/python
- sed -i -e "s:/usr/local/bin/python:/usr/bin/python:g" \
- "${S}"/bin/flow-{rptfmt,rpt2rrd,log2rrd}
-
- AM_OPTS="-f -i"
- eautoreconf || die "autoreconf failed"
-}
-
-src_compile() {
- use mysql && append-flags "-L/usr/lib/mysql -I/usr/include/mysql"
- use postgres && append-flags "-L/usr/lib/postgres -I/usr/include/postgres"
-
- econf \
- --localstatedir=/etc/flow-tools \
- --enable-lfs \
- $(use_with ssl openssl) \
- $(use_with mysql) \
- $(use_with postgres pgsql) \
- || die "econf failed"
-
- emake CFLAGS="${CFLAGS}" || die "emake failed"
-}
-
-src_install() {
- make DESTDIR="${D}" install || die "make install failed"
- dodoc ChangeLog README SECURITY TODO
-
- keepdir /var/lib/flows
- keepdir /var/lib/flows/bin
- exeinto /var/lib/flows/bin
- doexe "${FILESDIR}"/linkme
- keepdir /var/run/flows
-
- newinitd "${FILESDIR}/flowcapture.initd" flowcapture
- newconfd "${FILESDIR}/flowcapture.confd" flowcapture
-
-}
-
-pkg_postinst() {
- chown flows:flows /var/run/flows
- chown flows:flows /var/lib/flows
- chown flows:flows /var/lib/flows/bin
- chmod 0755 /var/run/flows
- chmod 0755 /var/lib/flows
- chmod 0755 /var/lib/flows/bin
-}
--- /dev/null
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/flow-tools/flow-tools-0.68.5.1.ebuild,v 1.1 2011/11/15 21:46:23 jer Exp $
+
+EAPI="2"
+
+inherit eutils
+
+DESCRIPTION="library and programs to collect, send, process, and generate reports from NetFlow data"
+HOMEPAGE="http://code.google.com/p/flow-tools/"
+SRC_URI="http://${PN}.googlecode.com/files/${P}.tar.bz2"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="mysql postgres debug ssl"
+
+RDEPEND="sys-apps/tcp-wrappers
+ sys-libs/zlib
+ mysql? ( virtual/mysql )
+ postgres? ( dev-db/postgresql-base )
+ ssl? ( dev-libs/openssl )"
+
+DEPEND="${RDEPEND}
+ sys-devel/flex
+ sys-devel/bison"
+
+pkg_setup() {
+ enewgroup flows
+ enewuser flows -1 -1 /var/lib/flows flows
+}
+
+src_configure() {
+ local myconf="--sysconfdir=/etc/flow-tools"
+ use mysql && myconf="${myconf} --with-mysql"
+ if use postgres; then
+ myconf="${myconf} --with-postgresql=yes"
+ else
+ myconf="${myconf} --with-postgresql=no"
+ fi
+ use ssl && myconf="${myconf} --with-openssl"
+ econf ${myconf} || die "econf failed"
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die "emake install failed"
+ dodoc ChangeLog README SECURITY TODO
+
+ keepdir /var/lib/flows
+ keepdir /var/lib/flows/bin
+ exeinto /var/lib/flows/bin
+ doexe "${FILESDIR}"/linkme
+ keepdir /var/run/flows
+
+ newinitd "${FILESDIR}/flowcapture.initd" flowcapture
+ newconfd "${FILESDIR}/flowcapture.confd" flowcapture
+
+}
+
+pkg_postinst() {
+ chown flows:flows /var/run/flows
+ chown flows:flows /var/lib/flows
+ chown flows:flows /var/lib/flows/bin
+ chmod 0755 /var/run/flows
+ chmod 0755 /var/lib/flows
+ chmod 0755 /var/lib/flows/bin
+}