svn commit: r206696 - head/sbin/hastd

Pawel Jakub Dawidek pjd at FreeBSD.org
Fri Apr 16 06:47:30 UTC 2010


Author: pjd
Date: Fri Apr 16 06:47:29 2010
New Revision: 206696
URL: http://svn.freebsd.org/changeset/base/206696

Log:
  Fix control socket leak when worker process exits.
  
  Submitted by:	Mikolaj Golub <to.my.trociny at gmail.com>
  MFC after:	3 days

Modified:
  head/sbin/hastd/hastd.c

Modified: head/sbin/hastd/hastd.c
==============================================================================
--- head/sbin/hastd/hastd.c	Fri Apr 16 02:56:24 2010	(r206695)
+++ head/sbin/hastd/hastd.c	Fri Apr 16 06:47:29 2010	(r206696)
@@ -137,6 +137,7 @@ child_exit(void)
 			pjdlog_error("Worker process failed (pid=%u, status=%d).",
 			    (unsigned int)pid, WEXITSTATUS(status));
 		}
+		proto_close(res->hr_ctrl);
 		res->hr_workerpid = 0;
 		if (res->hr_role == HAST_ROLE_PRIMARY) {
 			sleep(1);


More information about the svn-src-all mailing list