fixed a problem detected by the static checker.