pioneerspacesim/pioneer — pull request #1402 by johnbartholomew (2012-07-26 20:51:41+00:00)
Title: PVS-Studio fixes

See #1399.

This doesn't fix everything that PVS Studio found. I ignored the stuff from the collision detection code, and didn't want to change mtrand.

And there are various things that PVS Studio noted that aren't actually bugs, e.g.:

* The `COUNTOF` macro confuses it.
* `lua_pushboolean` technically takes an `int` but of course we always pass in a bool.
* The exact comparisons in `FloatComparison` are there precisely to help us avoid using them elsewhere.
* Sometimes two functions really should have the same body.