Some minor static analysis fixes