From: ian Date: Sun, 19 Sep 1999 19:02:51 +0000 (+0000) Subject: Pretty much works apart from some spare routes. X-Git-Tag: branchpoint-1996-06-19-retrospective-beforeuserv~19 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=userv-utils.git;a=commitdiff_plain;h=6d360a536b98cfa65d6ff447c666ecc66312d86e;ds=sidebyside Pretty much works apart from some spare routes. --- diff --git a/ipif/service.c b/ipif/service.c index 33ba2df..b76c754 100644 --- a/ipif/service.c +++ b/ipif/service.c @@ -75,7 +75,7 @@ static struct pplace { } *cpplace; -static int slpipe[2], ptmaster; +static int slpipe[2], ptmaster, undoslattach; static const char *ifname; static const char *ptyname; @@ -88,13 +88,36 @@ static union { sigset_t emptyset, fullset; +static int cleantask(void) { + pid_t pid; + + pid= fork(); + if (!pid) return 1; + if (pid == (pid_t)-1) + perror("userv-ipif: fork for undo slattach failed - cannot clean up properly"); + return 0; +} + static void terminate(int estatus) { int i, status; pid_t pid; for (i=0; i