Date: Sun, 16 Oct 2011 14:16:46 +0000 (UTC) From: Marcel Moolenaar <marcel@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r226435 - head/sys/kern Message-ID: <201110161416.p9GEGkoC065866@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: marcel Date: Sun Oct 16 14:16:46 2011 New Revision: 226435 URL: http://svn.freebsd.org/changeset/base/226435 Log: Fix double vision syndrome (read: double output) when in the debugger without a panic. Modified: head/sys/kern/subr_prf.c Modified: head/sys/kern/subr_prf.c ============================================================================== --- head/sys/kern/subr_prf.c Sun Oct 16 14:11:05 2011 (r226434) +++ head/sys/kern/subr_prf.c Sun Oct 16 14:16:46 2011 (r226435) @@ -467,25 +467,19 @@ putchar(int c, void *arg) struct putchar_arg *ap = (struct putchar_arg*) arg; struct tty *tp = ap->tty; int flags = ap->flags; - int putbuf_done = 0; /* Don't use the tty code after a panic or while in ddb. */ if (kdb_active) { if (c != '\0') cnputc(c); - } else { - if ((panicstr == NULL) && (flags & TOTTY) && (tp != NULL)) - tty_putchar(tp, c); - - if (flags & TOCONS) { - putbuf(c, ap); - putbuf_done = 1; - } - } - if ((flags & TOLOG) && (putbuf_done == 0)) { - if (c != '\0') - putbuf(c, ap); + return; } + + if ((flags & TOTTY) && tp != NULL && panicstr == NULL) + tty_putchar(tp, c); + + if ((flags & (TOCONS | TOLOG)) && c != '\0') + putbuf(c, ap); } /*
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201110161416.p9GEGkoC065866>