diff options
author | njl <njl@FreeBSD.org> | 2003-10-29 20:48:13 +0000 |
---|---|---|
committer | njl <njl@FreeBSD.org> | 2003-10-29 20:48:13 +0000 |
commit | 3fd708125c90c5c1c6c1b580faeed27376b68952 (patch) | |
tree | 34a955c1bf129794410c93ede2d478d15231c5b9 /sys/dev/syscons | |
parent | edb6523b57994eafd624cc470efad96c1ea66c4e (diff) | |
download | FreeBSD-src-3fd708125c90c5c1c6c1b580faeed27376b68952.zip FreeBSD-src-3fd708125c90c5c1c6c1b580faeed27376b68952.tar.gz |
Fix a panic that occurs when resuming. For some reason, sc->cur_scp is
NULL.
Submitted by: Andrew Thompson <andy@fud.org.nz>
Diffstat (limited to 'sys/dev/syscons')
-rw-r--r-- | sys/dev/syscons/syscons.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/dev/syscons/syscons.c b/sys/dev/syscons/syscons.c index 17daf5d..da76ed3 100644 --- a/sys/dev/syscons/syscons.c +++ b/sys/dev/syscons/syscons.c @@ -2147,6 +2147,9 @@ sc_switch_scr(sc_softc_t *sc, u_int next_scr) DPRINTF(5, ("sc0: sc_switch_scr() %d ", next_scr + 1)); + if (sc->cur_scp == NULL) + return (0); + /* prevent switch if previously requested */ if (sc->flags & SC_SCRN_VTYLOCK) { sc_bell(sc->cur_scp, sc->cur_scp->bell_pitch, |