Skip to content

Commit 31b71ea

Browse files
committed
C++: Fix annotations.
1 parent 40dde93 commit 31b71ea

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

cpp/ql/test/query-tests/Critical/MemoryFreed/test_free.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,9 @@ void test_dominance2(void *a) {
3939

4040
void test_post_dominance1(int *a)
4141
{
42-
if (condition()) free(a); // GOOD
43-
if (condition()) a[2] = 5; // GOOD
44-
if (condition()) free(a); // GOOD
42+
if (condition()) free(a);
43+
if (condition()) a[2] = 5; // BAD [NOT DETECTED]
44+
if (condition()) free(a); // BAD [NOT DETECTED]
4545
a[2] = 5; // BAD
4646
free(a); // BAD
4747
}

0 commit comments

Comments
 (0)