summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorray <ray@FreeBSD.org>2014-04-03 11:59:04 +0000
committerray <ray@FreeBSD.org>2014-04-03 11:59:04 +0000
commit003ac1d9a0df25662ff249364e9d61d968d7f61d (patch)
tree15c12339158d5a61a393e20e74720448aa0b3d8b
parent60e600a585782710f806977d1aa5d92f5d1299bc (diff)
downloadFreeBSD-src-003ac1d9a0df25662ff249364e9d61d968d7f61d.zip
FreeBSD-src-003ac1d9a0df25662ff249364e9d61d968d7f61d.tar.gz
MFC r263809
Fix crash on resume in vt(9). Statically allocated terminal window have not initialized callout handler, so we have to initialize it even for existing window if it is console window. Sponsored by: The FreeBSD Foundation
-rw-r--r--sys/dev/vt/vt_core.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/dev/vt/vt_core.c b/sys/dev/vt/vt_core.c
index 368c971..b179afd 100644
--- a/sys/dev/vt/vt_core.c
+++ b/sys/dev/vt/vt_core.c
@@ -1872,6 +1872,9 @@ vt_upgrade(struct vt_device *vd)
if (vw == NULL) {
/* New window. */
vw = vt_allocate_window(vd, i);
+ } else if (vw->vw_flags & VWF_CONSOLE) {
+ /* For existing console window. */
+ callout_init(&vw->vw_proc_dead_timer, 0);
}
if (i == VT_CONSWINDOW) {
/* Console window. */
OpenPOWER on IntegriCloud