Browse code

alls to clamfi_cleanup were missing

git-svn-id: file:///var/lib/svn/clamav-devel/trunk/clamav-devel@150 77e5149b-7576-45b1-b177-96237e5ba77b

Nigel Horne authored on 2003/12/12 22:44:44
Showing 3 changed files
... ...
@@ -1,3 +1,8 @@
1
+Fri Dec 12 13:43:50 GMT 2003 (njh)
2
+----------------------------------
3
+  * clamav-milter: A couple of calls to clamfi_cleanup were missing before
4
+	return cl_error
5
+
1 6
 Thu Dec 11 14:36:32 GMT 2003 (njh)
2 7
 ----------------------------------
3 8
   * libclamav: better handling of encapsulated messages, i.e. emails
... ...
@@ -174,6 +174,8 @@ Changes
174 174
 		Thanks to Michael Dankov <misha@btrc.ru>
175 175
 0.65i	9/12/03	Use the location of sendmail discovered by configure
176 176
 0.65j	10/12/03 Timeout on waiting for data from clamd
177
+0.65k	12/12/03 A couple of calls to clamfi_cleanup were missing
178
+		before return cl_error
177 179
 
178 180
 BUG REPORTS
179 181
 
... ...
@@ -177,9 +177,14 @@
177 177
  *			Thanks to Michael Dankov <misha@btrc.ru>
178 178
  *	0.65i	9/12/03	Use the location of sendmail discovered by configure
179 179
  *	0.65j	10/12/03 Timeout on waiting for data from clamd
180
+ *	0.65k	12/12/03 A couple of calls to clamfi_cleanup were missing
181
+ *			before return cl_error
180 182
  *
181 183
  * Change History:
182 184
  * $Log: clamav-milter.c,v $
185
+ * Revision 1.30  2003/12/12 13:42:47  nigelhorne
186
+ * alls to clamfi_cleanup were missing
187
+ *
183 188
  * Revision 1.29  2003/12/10 12:00:39  nigelhorne
184 189
  * Timeout on waiting for data from clamd
185 190
  *
... ...
@@ -252,9 +257,9 @@
252 252
  * Revision 1.6  2003/09/28 16:37:23  nigelhorne
253 253
  * Added -f flag use MaxThreads if --max-children not set
254 254
  */
255
-static	char	const	rcsid[] = "$Id: clamav-milter.c,v 1.29 2003/12/10 12:00:39 nigelhorne Exp $";
255
+static	char	const	rcsid[] = "$Id: clamav-milter.c,v 1.30 2003/12/12 13:42:47 nigelhorne Exp $";
256 256
 
257
-#define	CM_VERSION	"0.65j"
257
+#define	CM_VERSION	"0.65k"
258 258
 
259 259
 /*#define	CONFDIR	"/usr/local/etc"*/
260 260
 
... ...
@@ -1392,10 +1397,12 @@ clamfi_eom(SMFICTX *ctx)
1392 1392
 
1393 1393
 		if((privdata->cmdSocket = socket(AF_UNIX, SOCK_STREAM, 0)) < 0) {
1394 1394
 			perror("socket");
1395
+			clamfi_cleanup(ctx);
1395 1396
 			return cl_error;
1396 1397
 		}
1397 1398
 		if(connect(privdata->cmdSocket, (struct sockaddr *)&server, sizeof(struct sockaddr_un)) < 0) {
1398 1399
 			perror(localSocket);
1400
+			clamfi_cleanup(ctx);
1399 1401
 			return cl_error;
1400 1402
 		}
1401 1403
 
... ...
@@ -1424,6 +1431,7 @@ clamfi_eom(SMFICTX *ctx)
1424 1424
 		printf("clamfi_eom: read %s\n", mess);
1425 1425
 #endif
1426 1426
 	} else {
1427
+		clamfi_cleanup(ctx);
1427 1428
 		syslog(LOG_NOTICE, "clamfi_eom: read nothing from clamd");
1428 1429
 #ifdef	CL_DEBUG
1429 1430
 		puts("clamfi_eom: read nothing from clamd");