Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libcurses Fix the debug output to stop spamming out the ...
details: https://anonhg.NetBSD.org/src/rev/9be22ceac984
branches: trunk
changeset: 1021881:9be22ceac984
user: blymn <blymn%NetBSD.org@localhost>
date: Tue Jun 22 07:22:44 2021 +0000
description:
Fix the debug output to stop spamming out the aline for row 0, we
may not be working on that row so the output is pointless.
diffstat:
lib/libcurses/ins_wch.c | 27 ++++++---------------------
1 files changed, 6 insertions(+), 21 deletions(-)
diffs (60 lines):
diff -r 5f3e1b624e28 -r 9be22ceac984 lib/libcurses/ins_wch.c
--- a/lib/libcurses/ins_wch.c Tue Jun 22 03:39:21 2021 +0000
+++ b/lib/libcurses/ins_wch.c Tue Jun 22 07:22:44 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ins_wch.c,v 1.15 2020/07/06 22:46:50 uwe Exp $ */
+/* $NetBSD: ins_wch.c,v 1.16 2021/06/22 07:22:44 blymn Exp $ */
/*
* Copyright (c) 2005 The NetBSD Foundation Inc.
@@ -36,7 +36,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: ins_wch.c,v 1.15 2020/07/06 22:46:50 uwe Exp $");
+__RCSID("$NetBSD: ins_wch.c,v 1.16 2021/06/22 07:22:44 blymn Exp $");
#endif /* not lint */
#include <string.h>
@@ -95,19 +95,14 @@
if (!wch)
return OK;
cw = wcwidth(wch->vals[0]);
+#ifdef DEBUG
+ __CTRACE(__CTRACE_INPUT, "wins_wch: wcwidth %d\n", cw);
+#endif
if (cw < 0)
cw = 1;
if (!cw)
return wadd_wch( win, wch );
-#ifdef DEBUG
- __CTRACE(__CTRACE_INPUT, "--before--\n");
- for (x = 0; x < win->maxx; x++)
- __CTRACE(__CTRACE_INPUT, "wins_wch: (0,%d)=(%x,%x,%p)\n", x,
- win->alines[0]->line[x].ch,
- win->alines[0]->line[x].attr,
- win->alines[0]->line[x].nsp);
-#endif /* DEBUG */
x = win->curx;
y = win->cury;
#ifdef DEBUG
@@ -217,17 +212,7 @@
temp1->nsp = NULL;
ex++, temp1++;
}
-#ifdef DEBUG
- {
- __CTRACE(__CTRACE_INPUT, "--after---\n");
- for (x = 0; x < win->maxx; x++)
- __CTRACE(__CTRACE_INPUT,
- "wins_wch: (0,%d)=(%x,%x,%p)\n", x,
- win->alines[0]->line[x].ch,
- win->alines[0]->line[x].attr,
- win->alines[0]->line[x].nsp);
- }
-#endif /* DEBUG */
+
newx = win->maxx - 1 + win->ch_off;
if (newx > *lnp->lastchp)
*lnp->lastchp = newx;
Home |
Main Index |
Thread Index |
Old Index