freebsd-ports/games/crossfire-client/files/patch-common::misc.c
Jeremy Messenger 43c47254b5 Fix the build on 4.x.
PR:		ports/66388
Submitted by:	Mark Daniel Reidel <ports@mark.reidel.info> (maintainer)
Approved by:	adamw (mentor)
2004-05-11 04:41:44 +00:00

17 lines
619 B
C

--- common/misc.c.orig Sat May 8 15:31:29 2004
+++ common/misc.c Sat May 8 15:31:49 2004
@@ -237,13 +237,13 @@
#ifndef WIN32
ChildProcess* cp=FirstChild;
ChildProcess* last=NULL;
+ ChildProcess* next;
for (;;){
if (!cp)
return; /*no child to monitor*/
if (waitpid(cp->pid,NULL,WNOHANG)){
/*pid is dead*/
LOG(LOG_INFO,"common::monitorChilds","Child %s died. Removing and closing pipes",cp->name?cp->name:"UNKNOWN");
- ChildProcess* next;
if (cp==LastChild)
LastChild=last;
next=cp->next;