Use new cli_rndnum API

git-svn: trunk@3491
remotes/push_mirror/metadata
Nigel Horne 18 years ago
parent 12a7b4fbff
commit 66682bfa07
  1. 5
      ChangeLog
  2. 10
      clamav-milter/clamav-milter.c

@ -1,3 +1,8 @@
Thu Jan 10 11:23:32 GMT 2008 (njh)
----------------------------------
* clamav-milter: Use new cli_rndnum API - thanks to TK for spotting
this one
Wed Jan 9 20:13:52 CET 2008 (tk)
---------------------------------
* libclamav/others.c: improve cli_rndnum() and cli_gentempfd()

@ -33,7 +33,7 @@
*/
static char const rcsid[] = "$Id: clamav-milter.c,v 1.312 2007/02/12 22:24:21 njh Exp $";
#define CM_VERSION "devel-20071229"
#define CM_VERSION "devel-20080110"
#if HAVE_CONFIG_H
#include "clamav-config.h"
@ -2421,11 +2421,9 @@ findServer(void)
j = 0;
} else
/*
* cli_rndnum returns 0..(max-1) - the max argument is not
* the maximum number you want it to return, it is in fact
* one *more* than the maximum number you want it to return
* cli_rndnum returns 0..max
*/
j = cli_rndnum(numServers);
j = cli_rndnum(numServers - 1);
for(i = 0; i < numServers; i++)
socks[i].sock = -1;
@ -5954,7 +5952,7 @@ print_trace(void)
* clamav-milter before I put this check in!
*
* FIXME: return different codes for "the value is wrong" and "sendmail.cf"
* hasn't been set up
* hasn't been set up, though that's not so easy to work out.
*/
static int
verifyIncomingSocketName(const char *sockName)

Loading…
Cancel
Save