Deleted Added
full compact
pty.c (46112) pty.c (46676)
1/*
2 * Copyright (c) 1982, 1986, 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 17 unchanged lines hidden (view full) ---

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)tty_pty.c 8.4 (Berkeley) 2/20/95
1/*
2 * Copyright (c) 1982, 1986, 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 17 unchanged lines hidden (view full) ---

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)tty_pty.c 8.4 (Berkeley) 2/20/95
34 * $Id: tty_pty.c,v 1.55 1999/01/30 12:17:37 phk Exp $
34 * $Id: tty_pty.c,v 1.56 1999/04/27 11:16:19 phk Exp $
35 */
36
37/*
38 * Pseudo-teletype Driver
39 * (Actually two drivers, requiring two entries in 'cdevsw')
40 */
41#include "pty.h" /* XXX */
42#include "opt_compat.h"

--- 627 unchanged lines hidden (view full) ---

670 (pti->pt_flags & PF_PKT)) {
671 pti->pt_send |= TIOCPKT_IOCTL;
672 ptcwakeup(tp, FREAD);
673 }
674 tp->t_lflag &= ~EXTPROC;
675 }
676 return(0);
677 } else
35 */
36
37/*
38 * Pseudo-teletype Driver
39 * (Actually two drivers, requiring two entries in 'cdevsw')
40 */
41#include "pty.h" /* XXX */
42#include "opt_compat.h"

--- 627 unchanged lines hidden (view full) ---

670 (pti->pt_flags & PF_PKT)) {
671 pti->pt_send |= TIOCPKT_IOCTL;
672 ptcwakeup(tp, FREAD);
673 }
674 tp->t_lflag &= ~EXTPROC;
675 }
676 return(0);
677 } else
678 if (cdevsw[major(dev)]->d_open == ptcopen)
678 if (devsw(dev)->d_open == ptcopen)
679 switch (cmd) {
680
681 case TIOCGPGRP:
682 /*
683 * We avoid calling ttioctl on the controller since,
684 * in that case, tp must be the controlling terminal.
685 */
686 *(int *)data = tp->t_pgrp ? tp->t_pgrp->pg_id : 0;

--- 146 unchanged lines hidden ---
679 switch (cmd) {
680
681 case TIOCGPGRP:
682 /*
683 * We avoid calling ttioctl on the controller since,
684 * in that case, tp must be the controlling terminal.
685 */
686 *(int *)data = tp->t_pgrp ? tp->t_pgrp->pg_id : 0;

--- 146 unchanged lines hidden ---