some more cleanups from static analysis