Deleted Added
full compact
kern_cons.c (46112) kern_cons.c (46116)
1/*
2 * Copyright (c) 1988 University of Utah.
3 * Copyright (c) 1991 The Regents of the University of California.
4 * All rights reserved.
5 *
6 * This code is derived from software contributed to Berkeley by
7 * the Systems Programming Group of the University of Utah Computer
8 * Science Department.

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

31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * from: @(#)cons.c 7.2 (Berkeley) 5/9/91
1/*
2 * Copyright (c) 1988 University of Utah.
3 * Copyright (c) 1991 The Regents of the University of California.
4 * All rights reserved.
5 *
6 * This code is derived from software contributed to Berkeley by
7 * the Systems Programming Group of the University of Utah Computer
8 * Science Department.

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

31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * from: @(#)cons.c 7.2 (Berkeley) 5/9/91
39 * $Id: cons.c,v 1.61 1999/01/07 14:14:11 yokota Exp $
39 * $Id: cons.c,v 1.62 1999/04/27 11:14:29 phk Exp $
40 */
41
42#include "opt_devfs.h"
43
44#include <sys/param.h>
45#ifdef DEVFS
46#include <sys/devfsext.h>
47#endif /*DEVFS*/

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

353
354 if ((cn_tab == NULL) || cn_mute)
355 return (0);
356 /*
357 * Superuser can always use this to wrest control of console
358 * output from the "virtual" console.
359 */
360 if (cmd == TIOCCONS && constty) {
40 */
41
42#include "opt_devfs.h"
43
44#include <sys/param.h>
45#ifdef DEVFS
46#include <sys/devfsext.h>
47#endif /*DEVFS*/

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

353
354 if ((cn_tab == NULL) || cn_mute)
355 return (0);
356 /*
357 * Superuser can always use this to wrest control of console
358 * output from the "virtual" console.
359 */
360 if (cmd == TIOCCONS && constty) {
361 error = suser_xxx(p->p_ucred, (u_short *) NULL);
361 error = suser(p);
362 if (error)
363 return (error);
364 constty = NULL;
365 return (0);
366 }
367 dev = cn_tab->cn_dev;
368 return ((*cdevsw[major(dev)]->d_ioctl)(dev, cmd, data, flag, p));
369}

--- 69 unchanged lines hidden ---
362 if (error)
363 return (error);
364 constty = NULL;
365 return (0);
366 }
367 dev = cn_tab->cn_dev;
368 return ((*cdevsw[major(dev)]->d_ioctl)(dev, cmd, data, flag, p));
369}

--- 69 unchanged lines hidden ---