Skip to content

Commit

Permalink
fix memory leak in fs.scandir sync mode
Browse files Browse the repository at this point in the history
  • Loading branch information
zhaozg committed Feb 23, 2024
1 parent 372da9d commit 0e4a895
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/fs.c
Original file line number Diff line number Diff line change
Expand Up @@ -470,6 +470,9 @@ static void luv_fs_cb(uv_fs_t* req) {
luv_cleanup_req(L, lreq); \
req->data = NULL; \
uv_fs_req_cleanup(req); \
} else { \
luaL_unref(L, LUA_REGISTRYINDEX, lreq->req_ref); \
lreq->req_ref = LUA_NOREF; \
} \
} \
else { \
Expand Down

0 comments on commit 0e4a895

Please sign in to comment.