Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: PATCH: remove dead code flagged by coverity
- X-seq: zsh-workers 42596
- From: Peter Stephenson <p.stephenson@xxxxxxxxxxx>
- To: Zsh workers <zsh-workers@xxxxxxx>
- Subject: Re: PATCH: remove dead code flagged by coverity
- Date: Thu, 05 Apr 2018 14:29:00 +0100
- Cms-type: 201P
- Dkim-filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20180405132907euoutp027a38c210e2f805bd9b745ecd3ba9038d~ijUQipoj21885518855euoutp02O
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1522934947; bh=5fZfh5q+FeoBjnAD5PHb3qZ/nzvV27YXYZJDQ3Al15g=; h=Date:From:To:Subject:In-reply-to:References:From; b=qsSfjWRS6t9hbyAKX/KcNGVPCNGmj0teJm7UBS5hz1MFELv4+dGD/3YVw+cS94RdG cRHvKgE3qwKeVdfovU+dg1BHq+ViMjF3k0ZISWFD55kqlT1Ol6eZh2zg4WuT1FqOC3 giSuydCyOAVPUtitQgwosp0WcBtKA6Rt0czJsUvQ=
- In-reply-to: <26567.1522930146@thecus>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- List-unsubscribe: <mailto:zsh-workers-unsubscribe@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- Organization: SCSC
- References: <CGME20180405121007epcas4p383511f24b9e1aedbdee704db42382368@epcas4p3.samsung.com> <26567.1522930146@thecus>
On Thu, 05 Apr 2018 14:09:06 +0200
Oliver Kiddle <okiddle@xxxxxxxxxxx> wrote:
> Coverity correctly flags these two lines of code as being dead. This
> was added in 42332. Unless the intention was instead for
> zstrtoul_underscore() to also handle base#number syntax then this can
> go because it only looks for binary, octal, decimal and hex.
The only use of the function is to ensure we can get a maximum length
unsigned integer. The presence of base# would cause that case to
drop through to a mathevali(), which is what this code always
used before.
Logically, there is a gap as this doesn't handle 16#ffffffffffffffff,
I suppose.
pws
Messages sorted by:
Reverse Date,
Date,
Thread,
Author