From: Joerg Sonnenberger <joerg@britannica.bec.de>
To: source@mdocml.bsd.lv
Subject: Re: mdocml: Regression fixes after merging 1.11.3 to OpenBSD (rev.
Date: Sun, 31 Jul 2011 13:31:23 +0200 [thread overview]
Message-ID: <20110731113123.GB2434@britannica.bec.de> (raw)
In-Reply-To: <201107311124.p6VBOdOn017859@krisdoz.my.domain>
On Sun, Jul 31, 2011 at 07:24:39AM -0400, schwarze@mdocml.bsd.lv wrote:
> diff -Lchars.c -Lchars.c -u -p -r1.49 -r1.50
> --- chars.c
> +++ chars.c
> @@ -113,7 +113,7 @@ mchars_num2char(const char *p, size_t sz
>
> if ((i = mandoc_strntoi(p, sz, 10)) < 0)
> return('\0');
> - return(isprint(i) ? i : '\0');
> + return(i > 0 && i < 256 && isprint(i) ? i : '\0');
> }
>
> int
Any reason why this doesn't use i>=0? That would allow the compiler to
merge both tests by using a bitmask...
Joerg
--
To unsubscribe send an email to source+unsubscribe@mdocml.bsd.lv
prev parent reply other threads:[~2011-07-31 11:31 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-31 11:24 schwarze
2011-07-31 11:31 ` Joerg Sonnenberger [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20110731113123.GB2434@britannica.bec.de \
--to=joerg@britannica.bec.de \
--cc=source@mdocml.bsd.lv \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).