date and time created 83/07/12 17:20:51 by edward
authorEdward Wang <edward@ucbvax.Berkeley.EDU>
Wed, 13 Jul 1983 08:20:51 +0000 (00:20 -0800)
committerEdward Wang <edward@ucbvax.Berkeley.EDU>
Wed, 13 Jul 1983 08:20:51 +0000 (00:20 -0800)
SCCS-vsn: usr.bin/window/wwspawn.c 1.1

usr/src/usr.bin/window/wwspawn.c [new file with mode: 0644]

diff --git a/usr/src/usr.bin/window/wwspawn.c b/usr/src/usr.bin/window/wwspawn.c
new file mode 100644 (file)
index 0000000..0641798
--- /dev/null
@@ -0,0 +1,20 @@
+#ifndef lint
+static char *sccsid = "@(#)wwspawn.c   1.1 83/07/12";
+#endif
+
+#include "ww.h"
+
+wwfork(wp)
+register struct ww *wp;
+{
+       switch (wp->ww_pid = fork()) {
+       case -1:
+               return -1;
+       case 0:
+               wp->ww_state = WW_INCHILD;
+               return 0;
+       default:
+               wp->ww_state = WW_HASPROC;
+               return wp->ww_pid;
+       }
+}