BUG: restore api of npy_PyFile_DupClose in python2

breaks matplotlib
Merge pull request #5067 from juliantaylor/restore-dup

BUG: restore api of npy_PyFile_DupClose in python2