From 26f08471345c3acb83f0fd8c3c9c99c249e47bfe Mon Sep 17 00:00:00 2001 From: Otto Moerbeek Date: Thu, 4 Aug 2005 09:48:28 +0000 Subject: Fix handling of empty entries at the end of an address list; avoids always skipping the last address. ok beck@ --- libexec/spamd/sdl.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'libexec/spamd/sdl.c') diff --git a/libexec/spamd/sdl.c b/libexec/spamd/sdl.c index 16cf8f6a3f7..bfac803ee6e 100644 --- a/libexec/spamd/sdl.c +++ b/libexec/spamd/sdl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sdl.c,v 1.12 2004/02/26 08:18:56 deraadt Exp $ */ +/* $OpenBSD: sdl.c,v 1.13 2005/08/04 09:48:27 otto Exp $ */ /* * Copyright (c) 2003 Bob Beck. All rights reserved. @@ -75,11 +75,12 @@ sdl_add(char *sdname, char *sdstring, char ** addrs, int addrc) } if (index != -1) { if (debug > 0) - printf("replacing list %s\n", blacklists[index].tag); + printf("replacing list %s; %d new entries\n", + blacklists[index].tag, addrc); sdl_free(&blacklists[index]); } else { if (debug > 0) - printf("adding list %s\n", sdname); + printf("adding list %s; %d entries\n", sdname, addrc); index = blu; } if (index == blu && blu == blc) { -- cgit v1.2.3