Skip to content

Commit

Permalink
deps: update googletest to 305e5a2
Browse files Browse the repository at this point in the history
PR-URL: #53157
Reviewed-By: Marco Ippolito <[email protected]>
Reviewed-By: Michaël Zasso <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Ulises Gascón <[email protected]>
Reviewed-By: Rafael Gonzaga <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
nodejs-github-bot authored and marco-ippolito committed Aug 19, 2024
1 parent 51e736a commit c01ce60
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions deps/googletest/src/gtest.cc
Original file line number Diff line number Diff line change
Expand Up @@ -6700,17 +6700,17 @@ void ParseGoogleTestFlagsOnlyImpl(int* argc, CharType** argv) {
}

if (remove_flag) {
// Shift the remainder of the argv list left by one. Note
// that argv has (*argc + 1) elements, the last one always being
// NULL. The following loop moves the trailing NULL element as
// well.
for (int j = i; j != *argc; j++) {
argv[j] = argv[j + 1];
// Shift the remainder of the argv list left by one.
for (int j = i + 1; j < *argc; ++j) {
argv[j - 1] = argv[j];
}

// Decrements the argument count.
(*argc)--;

// Terminate the array with nullptr.
argv[*argc] = nullptr;

// We also need to decrement the iterator as we just removed
// an element.
i--;
Expand Down

0 comments on commit c01ce60

Please sign in to comment.