mirror of
https://github.com/danog/ext-uv.git
synced 2024-11-30 04:29:01 +01:00
Fix uv_fs_scandir returning 0 as status instead of true on empty directory
This commit is contained in:
parent
d3433a1875
commit
72aa710358
2
php_uv.c
2
php_uv.c
@ -1829,7 +1829,7 @@ static void php_uv_fs_cb(uv_fs_t* req)
|
||||
|
||||
case UV_FS_SCANDIR:
|
||||
argc = 2;
|
||||
if (uv->uv.fs.result < 0 || req->ptr == NULL) {
|
||||
if (uv->uv.fs.result < 0) { /* req->ptr may be NULL here, but uv_fs_scandir_next() knows to handle it */
|
||||
ZVAL_LONG(¶ms[1], uv->uv.fs.result);
|
||||
} else {
|
||||
uv_dirent_t dent;
|
||||
|
Loading…
Reference in New Issue
Block a user