clean up static analysis warnings

Reviewer: trivial