More fixes for FindBugs warnings

The fixes are very simple and non-intrusive. All tests succeeded locally.