fix some pmd/findbugs warnings