Skip to content

Commit

Permalink
Bug 1447795: Add even more UseItOrLoseIt to SmokeDMD.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
David Major committed Apr 1, 2018
1 parent afdd07f commit fa8d998
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions memory/replace/dmd/test/SmokeDMD.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ void Foo(int aSeven)
char* a[6];
for (int i = 0; i < aSeven - 1; i++) {
a[i] = (char*) malloc(128 - 16*i);
UseItOrLoseIt(a[i], aSeven);
}

// Oddly, some versions of clang will cause identical stack traces to be
Expand All @@ -79,6 +80,7 @@ void Foo(int aSeven)

for (int i = 0; i < aSeven - 5; i++) {
Report(a[i]); // reported
UseItOrLoseIt(a[i], aSeven);
}

UseItOrLoseIt(a[2], aSeven);
Expand Down

0 comments on commit fa8d998

Please sign in to comment.