Skip to content

Commit

Permalink
Merge pull request numpy#12355 from hmaarrfk/tiny_bug_from_file
Browse files Browse the repository at this point in the history
BUG: fix a bug in npy_PyFile_Dup2 where it didn't return immediately on failure
  • Loading branch information
eric-wieser authored Nov 9, 2018
2 parents 8715400 + cb7eeb9 commit 7d80a40
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions numpy/core/include/numpy/npy_3kcompat.h
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,7 @@ npy_PyFile_Dup2(PyObject *file, char *mode, npy_off_t *orig_pos)
if (handle == NULL) {
PyErr_SetString(PyExc_IOError,
"Getting a FILE* from a Python file object failed");
return NULL;
}

/* Record the original raw file handle position */
Expand Down

0 comments on commit 7d80a40

Please sign in to comment.