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 <[email protected]>
---

 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();
 }
 
 /*

_______________________________________________
devel mailing list
[email protected]
http://www.open-fcoe.org/mailman/listinfo/devel

Reply via email to