Module Name: src Committed By: christos Date: Fri Jun 28 14:44:15 UTC 2013
Modified Files: src/sys/dev/hpc: hpf1275a_tty.c Log Message: fix uninitialized pointer. This could have never worked. http://m00nbsd.net/ae123a9bae03f7dde5c6d654412daf5a.html To generate a diff of this commit: cvs rdiff -u -r1.26 -r1.27 src/sys/dev/hpc/hpf1275a_tty.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/dev/hpc/hpf1275a_tty.c diff -u src/sys/dev/hpc/hpf1275a_tty.c:1.26 src/sys/dev/hpc/hpf1275a_tty.c:1.27 --- src/sys/dev/hpc/hpf1275a_tty.c:1.26 Sat Oct 27 13:18:17 2012 +++ src/sys/dev/hpc/hpf1275a_tty.c Fri Jun 28 10:44:15 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: hpf1275a_tty.c,v 1.26 2012/10/27 17:18:17 chs Exp $ */ +/* $NetBSD: hpf1275a_tty.c,v 1.27 2013/06/28 14:44:15 christos Exp $ */ /* * Copyright (c) 2004 Valeriy E. Ushakov @@ -28,7 +28,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: hpf1275a_tty.c,v 1.26 2012/10/27 17:18:17 chs Exp $"); +__KERNEL_RCSID(0, "$NetBSD: hpf1275a_tty.c,v 1.27 2013/06/28 14:44:15 christos Exp $"); #include "opt_wsdisplay_compat.h" @@ -307,7 +307,7 @@ hpf1275a_open(dev_t dev, struct tty *tp) .cf_fstate = FSTATE_STAR, }; struct lwp *l = curlwp; /* XXX */ - struct hpf1275a_softc *sc; + struct hpf1275a_softc *sc = device_private(self); device_t self; int error, s; @@ -328,7 +328,7 @@ hpf1275a_open(dev_t dev, struct tty *tp) return (EIO); } - tp->t_sc = device_private(self); + tp->t_sc = sc; sc->sc_tp = tp; splx(s);