git: 93ebd6307efe - main - vt: panic while changing vt font
Toomas Soome
tsoome at FreeBSD.org
Tue Jan 26 23:07:22 UTC 2021
The branch main has been updated by tsoome:
URL: https://cgit.FreeBSD.org/src/commit/?id=93ebd6307efeb95a29bc614edd0c67c2af850e98
commit 93ebd6307efeb95a29bc614edd0c67c2af850e98
Author: Toomas Soome <tsoome at FreeBSD.org>
AuthorDate: 2021-01-24 18:59:36 +0000
Commit: Toomas Soome <tsoome at FreeBSD.org>
CommitDate: 2021-01-26 23:07:03 +0000
vt: panic while changing vt font
Set refcount for loader provided font to 1 to prevent this font
from being released (so we can reset to default).
PR: 252833
---
sys/dev/vt/vt_core.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/sys/dev/vt/vt_core.c b/sys/dev/vt/vt_core.c
index 2352ed823424..ac89d8635e78 100644
--- a/sys/dev/vt/vt_core.c
+++ b/sys/dev/vt/vt_core.c
@@ -1528,6 +1528,8 @@ parse_font_info(struct font_info *fi)
ptr = roundup2(ptr, 8);
vfp = &vt_font_loader;
+ /* This is default font, set refcount 1 to disable removal. */
+ vfp->vf_refcount = 1;
vfp->vf_height = fi->fi_height;
vfp->vf_width = fi->fi_width;
for (unsigned i = 0; i < VFNT_MAPS; i++) {
More information about the dev-commits-src-all
mailing list