This commit is contained in:
CismonX 2018-11-08 22:49:58 +08:00
parent e4a0cc2df8
commit cf09a314b2
1 changed files with 2 additions and 2 deletions

View File

@ -2594,7 +2594,7 @@ PHP_METHOD(Collection, shuffle)
Z_TRY_ADDREF_P(val);
zend_hash_next_index_insert(shuffled, val);
ZEND_HASH_FOREACH_END();
size_t offset = 0;
uint32_t offset = 0;
Bucket* bucket = shuffled->arData;
for (; offset < num_elements - 1; ++offset) {
zend_long rand_idx = php_mt_rand_range(offset, num_elements - 1);
@ -2613,7 +2613,7 @@ PHP_METHOD(Collection, shuffled)
Z_TRY_ADDREF_P(val);
zend_hash_next_index_insert(shuffled, val);
ZEND_HASH_FOREACH_END();
size_t offset = 0;
uint32_t offset = 0;
Bucket* bucket = shuffled->arData;
for (; offset < num_elements - 1; ++offset) {
zend_long rand_idx = php_mt_rand_range(offset, num_elements - 1);