re #9420 fix cppcheck performance warning