Fix a bug introduced in previous py3 commit.