[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v4 08/34] vmap: Make the while loop less fishy.



On 15/03/16 17:56, Konrad Rzeszutek Wilk wrote:
> It looks like it could underflow at first glance. That is
> if i is zero and you get in the while loop with the
> i--. However the postfix expression is evaluated after the
> conditional so the loop is fine and won't execute (with i==0).
>
> However in spirit of defense programming lets clarify
> the loop conditional.
>
> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>

Reviewed-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>

This looks as if it will quieten Coverity, even though it is no
functional change.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.