new copyright notice
[unix-history] / usr / src / lib / libc / compat-43 / killpg.c
CommitLineData
e7f3e26f
MK
1/*
2 * Copyright (c) 1989 The Regents of the University of California.
3 * All rights reserved.
4 *
269a7923 5 * %sccs.include.redist.c%
e7f3e26f
MK
6 */
7
8#if defined(LIBC_SCCS) && !defined(lint)
269a7923 9static char sccsid[] = "@(#)killpg.c 5.2 (Berkeley) %G%";
e7f3e26f
MK
10#endif /* LIBC_SCCS and not lint */
11
12#include <sys/types.h>
13#include <sys/errno.h>
14
15/*
16 * Backwards-compatible killpg().
17 */
18killpg(pgid, sig)
19 pid_t pgid;
20 int sig;
21{
22 extern int errno;
23
24 if (pgid == 1) {
25 errno = ESRCH;
26 return (-1);
27 }
28 return (kill(-pgid, sig));
29}