cppcheck had the right idea, but the wrong scope on this one.