diff options
author | 1998-11-04 21:21:24 +0000 | |
---|---|---|
committer | 1998-11-04 21:21:24 +0000 | |
commit | 43b0c78d4d89d4c2c0300bc397cee57be4800d66 (patch) | |
tree | 75bbadb75c77e5c42aae97a1530c488fab78b80c /lib/libocurses/cr_put.c | |
parent | protos for strlcat, strlcpy (diff) | |
download | wireguard-openbsd-43b0c78d4d89d4c2c0300bc397cee57be4800d66.tar.xz wireguard-openbsd-43b0c78d4d89d4c2c0300bc397cee57be4800d66.zip |
Some -Wall and use strlcpy
Diffstat (limited to 'lib/libocurses/cr_put.c')
-rw-r--r-- | lib/libocurses/cr_put.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/libocurses/cr_put.c b/lib/libocurses/cr_put.c index ada2df5ca1e..d98e66b50e0 100644 --- a/lib/libocurses/cr_put.c +++ b/lib/libocurses/cr_put.c @@ -100,11 +100,12 @@ fgoto(in_refresh) outcol %= COLS; if (AM == 0) { while (l > 0) { - if (__pfast) + if (__pfast) { if (CR) tputs(CR, 0, __cputchar); else putchar('\r'); + } if (NL) tputs(NL, 0, __cputchar); else @@ -297,7 +298,7 @@ plod(cnt, in_refresh) * If it will be cheaper, or if we can't back up, then send a return * preliminarily. */ - if (j > i + 1 || outcol > destcol && !BS && !BC) { + if (j > i + 1 || (outcol > destcol && !BS && !BC)) { /* * BUG: this doesn't take the (possibly long) length of CR * into account. @@ -383,7 +384,7 @@ dontcr: while (outline < destline) { * Move one char to the right. We don't use ND space because * it's better to just print the char we are moving over. */ - if (in_refresh) + if (in_refresh) { if (plodflg) /* Avoid a complex calculation. */ plodcnt--; else { @@ -395,7 +396,7 @@ dontcr: while (outline < destline) { else goto nondes; } - else + } else nondes: if (ND) tputs(ND, 0, plodput); else |