5 /* (c) Copyright 1988 by the Massachusetts Institute of Technology. */
6 /* For copying and distribution information, please see the file */
7 /* <mit-copyright.h>. */
10 static char *rcsid_exec_002_c = "$Header$";
13 #include <mit-copyright.h>
22 extern CONNECTION conn;
23 extern int code, errno;
35 mask = sigblock(sigmask(SIGCHLD));
41 log_priority = log_ERROR;
42 com_err(whoami, errno, ": can't fork to run install script");
43 code = send_object(conn, (char *)&n, INTEGER_T);
48 execlp(str, str, (char *)NULL);
51 log_priority = log_ERROR;
52 com_err(whoami, n, ": %s", str);
53 (void) send_object(conn, (char *)&n, INTEGER_T);
58 } while (n != -1 && n != pid);
61 n = waitb.w_retcode + sms_err_base;
62 log_priority = log_ERROR;
63 com_err(whoami, n, " child exited with status %d", waitb.w_retcode);
64 code = send_object(conn, (char *)&n, INTEGER_T);