summaryrefslogtreecommitdiff
path: root/win32/winutil.c
diff options
context:
space:
mode:
authorAnatol Belski <ab@php.net>2014-10-28 19:29:07 +0100
committerAnatol Belski <ab@php.net>2014-10-29 15:30:02 +0100
commit842a98ef3213107c2e3746e54623c271f99114d9 (patch)
tree40c608ecee6b3616321ba7fed505b65baa4ce4b5 /win32/winutil.c
parent9fd0364576c470c1a1febc003eace88fe8d19c8d (diff)
downloadphp-git-842a98ef3213107c2e3746e54623c271f99114d9.tar.gz
fix datatype mismatch warn
Diffstat (limited to 'win32/winutil.c')
-rw-r--r--win32/winutil.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/win32/winutil.c b/win32/winutil.c
index 5203fb4e66..eab3df9cda 100644
--- a/win32/winutil.c
+++ b/win32/winutil.c
@@ -115,7 +115,8 @@ PHPAPI int php_win32_get_random_bytes(unsigned char *buf, size_t size) { /* {{{
return FAILURE;
}
- ret = CryptGenRandom(hCryptProv, size, buf);
+ /* XXX should go in the loop if size exceeds UINT_MAX */
+ ret = CryptGenRandom(hCryptProv, (DWORD)size, buf);
if (ret) {
return SUCCESS;