-/* $OpenBSD: tcgetpgrp.c,v 1.6 2013/04/17 17:40:35 tedu Exp $ */
+/* $OpenBSD: tcgetpgrp.c,v 1.7 2014/12/16 03:32:21 millert Exp $ */
/*-
* Copyright (c) 1989, 1993
* The Regents of the University of California. All rights reserved.
* SUCH DAMAGE.
*/
-#include <sys/types.h>
#include <sys/ioctl.h>
-#include <termios.h>
#include <unistd.h>
pid_t
int s;
if (ioctl(fd, TIOCGPGRP, &s) < 0)
- return ((pid_t)-1);
+ return (-1);
- return ((pid_t)s);
+ return (s);
}
-/* $OpenBSD: tcsetpgrp.c,v 1.7 2013/04/17 17:40:35 tedu Exp $ */
+/* $OpenBSD: tcsetpgrp.c,v 1.8 2014/12/16 03:32:21 millert Exp $ */
/*-
* Copyright (c) 1989, 1993
* The Regents of the University of California. All rights reserved.
* SUCH DAMAGE.
*/
-#include <sys/types.h>
#include <sys/ioctl.h>
-#include <termios.h>
#include <unistd.h>
int