diff options
Diffstat (limited to 'test/Analysis/malloc-annotations.c')
-rw-r--r-- | test/Analysis/malloc-annotations.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/test/Analysis/malloc-annotations.c b/test/Analysis/malloc-annotations.c index 089e53132d..1dc0f7837b 100644 --- a/test/Analysis/malloc-annotations.c +++ b/test/Analysis/malloc-annotations.c @@ -70,10 +70,9 @@ void af1_c() { myglobalpointer = my_malloc(12); // no-warning } -// TODO: We will be able to handle this after we add support for tracking allocations stored in struct fields. void af1_d() { struct stuff mystuff; - mystuff.somefield = my_malloc(12); // false negative + mystuff.somefield = my_malloc(12); // expected-warning{{Memory is never released; potential leak}} } // Test that we can pass out allocated memory via pointer-to-pointer. |