[Open-FCoE] [PATCH 14/15] fcoe-utils: wait() for child processes to complete

Robert Love robert.w.love at intel.com
Thu Jul 16 17:01:34 UTC 2009


Previously fcoemon was leaving <defunct> processes for every
child that was spawned for fcoeplumb. This patch adds the
wait() call for the parent process after forking the child
which causes fcoemon to wait until fcoeplumb completes
execution before continuing.

Signed-off-by: Robert Love <robert.w.love at intel.com>
---

 fcoemon.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/fcoemon.c b/fcoemon.c
index bd51095..e6b1a32 100644
--- a/fcoemon.c
+++ b/fcoemon.c
@@ -1649,7 +1649,8 @@ static void fcm_dcbd_setup(struct fcm_fcoe *ff, enum fcoeadm_action action)
 
 		FCM_LOG_ERR(errno, "exec '%s' failed", fcm_dcbd_cmd);
 		exit(1);
-	}
+	} else
+		wait();
 }
 
 /*




More information about the devel mailing list