We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 59d3594 commit 5e70befCopy full SHA for 5e70bef
1 file changed
Modules/posixmodule.c
@@ -1637,7 +1637,7 @@ static int
1637
fd_and_follow_symlinks_invalid(const char *function_name, int fd,
1638
int follow_symlinks)
1639
{
1640
- if ((fd > 0) && (!follow_symlinks)) {
+ if ((fd >= 0) && (!follow_symlinks)) {
1641
PyErr_Format(PyExc_ValueError,
1642
"%s: cannot use fd and follow_symlinks together",
1643
function_name);
0 commit comments