fix klocwork defect
fix test failure