@@ -434,9 +434,9 @@ auto spawn_async(SpawnOptions const& opts) -> Result<AsyncProcess>
434434 CloseHandle (pi.hThread );
435435
436436 return AsyncProcess {
437- .pid = reinterpret_cast <std::intptr_t >(pi.hProcess ), // NOLINT(cppcoreguidelines-pro-type-reinterpret-cast)
438- .stdout_fd = reinterpret_cast <std::intptr_t >(stdout_read), // NOLINT(cppcoreguidelines-pro-type-reinterpret-cast)
439- .stderr_fd = reinterpret_cast <std::intptr_t >(stderr_read), // NOLINT(cppcoreguidelines-pro-type-reinterpret-cast)
437+ .pid = reinterpret_cast <std::intptr_t >(pi.hProcess ), // NOLINT(cppcoreguidelines-pro-type-reinterpret-cast)
438+ .stdout_fd = reinterpret_cast <std::intptr_t >(stdout_read), // NOLINT(cppcoreguidelines-pro-type-reinterpret-cast)
439+ .stderr_fd = reinterpret_cast <std::intptr_t >(stderr_read), // NOLINT(cppcoreguidelines-pro-type-reinterpret-cast)
440440 };
441441}
442442
@@ -448,7 +448,7 @@ auto poll_fds(PollableFd* fds, std::size_t count, int timeout_ms) -> int
448448 }
449449
450450 // Save original fds for restoration on ready
451- std::intptr_t stack_originals[64 ]; // NOLINT(modernize-avoid-c-arrays)
451+ std::intptr_t stack_originals[64 ]; // NOLINT(modernize-avoid-c-arrays)
452452 auto * originals = count <= 64 ? stack_originals : new std::intptr_t [count]; // NOLINT
453453 for (std::size_t i = 0 ; i < count; ++i) {
454454 originals[i] = fds[i].fd ;
@@ -478,12 +478,16 @@ auto poll_fds(PollableFd* fds, std::size_t count, int timeout_ms) -> int
478478 }
479479
480480 if (found > 0 ) {
481- if (count > 64 ) { delete[] originals; } // NOLINT
481+ if (count > 64 ) {
482+ delete[] originals;
483+ } // NOLINT
482484 return found;
483485 }
484486
485487 if (!infinite && GetTickCount64 () >= deadline) {
486- if (count > 64 ) { delete[] originals; } // NOLINT
488+ if (count > 64 ) {
489+ delete[] originals;
490+ } // NOLINT
487491 return 0 ;
488492 }
489493
0 commit comments