Skip to content

Commit

Permalink
Revert "src: simplify format in node_file.cc"
Browse files Browse the repository at this point in the history
This reverts commit 673f49a.

This change is breaking gulp on v14.x. Reverting so we can reland in a
way that doesn't break stuff

Refs: nodejs#33660
Refs: nodejs#34371
  • Loading branch information
MylesBorins committed Jul 21, 2020
1 parent da95dd7 commit 4761579
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/node_file.cc
Expand Up @@ -488,9 +488,9 @@ int FileHandle::ReadStart() {

// Push the read wrap back to the freelist, or let it be destroyed
// once we’re exiting the current scope.
constexpr size_t kWantedFreelistFill = 100;
constexpr size_t wanted_freelist_fill = 100;
auto& freelist = handle->binding_data_->file_handle_read_wrap_freelist;
if (freelist.size() < kWantedFreelistFill) {
if (freelist.size() < wanted_freelist_fill) {
read_wrap->Reset();
freelist.emplace_back(std::move(read_wrap));
}
Expand Down Expand Up @@ -758,7 +758,7 @@ void AfterScanDir(uv_fs_t* req) {
int r;
std::vector<Local<Value>> name_v;

for (;;) {
for (int i = 0; ; i++) {
uv_dirent_t ent;

r = uv_fs_scandir_next(req, &ent);
Expand Down Expand Up @@ -799,7 +799,7 @@ void AfterScanDirWithTypes(uv_fs_t* req) {
std::vector<Local<Value>> name_v;
std::vector<Local<Value>> type_v;

for (;;) {
for (int i = 0; ; i++) {
uv_dirent_t ent;

r = uv_fs_scandir_next(req, &ent);
Expand Down

0 comments on commit 4761579

Please sign in to comment.