1 /* PR middle-end/104069 - -Werror=use-after-free false positive on
4 { dg-options "-Wall" } */
6 typedef __SIZE_TYPE__
size_t;
8 extern void* realloc (void *, size_t);
10 void* __libdw_unzstd (size_t todo
)
19 char *b
= realloc (sb
, todo
);
31 // Shrink buffer: leave only one byte for simplicity.
32 char *b
= realloc (sb
, 1);
37 // Realloc failed mysteriously, leave 'sb' untouched.
40 return sb
; // { dg-bogus "-Wuse-after-free" }