Fix logic error and DECREF reported by Coverity.
1 file changed