From 8cd903ea685a6ef56aa77e95c00db8aac53a7c39 Mon Sep 17 00:00:00 2001 From: Anatol Belski Date: Thu, 10 Mar 2016 11:35:50 +0100 Subject: [PATCH] fix error condition, part of bug #71753 --- ext/standard/flock_compat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/standard/flock_compat.c b/ext/standard/flock_compat.c index f895412442..99f71ac380 100644 --- a/ext/standard/flock_compat.c +++ b/ext/standard/flock_compat.c @@ -127,7 +127,7 @@ PHPAPI int php_flock(int fd, int operation) {0, 0, 0, 0, NULL}; DWORD err; - if (hdl < 0) { + if (INVALID_HANDLE_VALUE == hdl) { _set_errno(EBADF); return -1; /* error in file descriptor */ } -- 2.40.0