Skip to content

Commit 3802a30

Browse files
committed
FIX file_get_contents() on Windows fails with "errno=22 Invalid argument"
1 parent ed84bcd commit 3802a30

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

main/streams/plain_wrapper.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ extern int php_get_gid_by_name(const char *name, gid_t *gid);
5454
#endif
5555

5656
#if defined(PHP_WIN32)
57-
# define PLAIN_WRAP_BUF_SIZE(st) (((st) > UINT_MAX) ? UINT_MAX : (unsigned int)(st))
57+
# define PLAIN_WRAP_BUF_SIZE(st) ((unsigned int)(st > INT_MAX ? INT_MAX : st))
5858
#define fsync _commit
5959
#define fdatasync fsync
6060
#else

0 commit comments

Comments
 (0)