81 data->alloc_total++; |
81 data->alloc_total++; |
82 if (ptr == NULL) { |
82 if (ptr == NULL) { |
83 data->alloc_failed++; |
83 data->alloc_failed++; |
84 } else { |
84 } else { |
85 data->free_total++; |
85 data->free_total++; |
|
86 #pragma GCC diagnostic push |
|
87 #pragma GCC diagnostic ignored "-Wuse-after-free" |
86 if (!cx_testing_allocator_untrack(data, mem)) { |
88 if (!cx_testing_allocator_untrack(data, mem)) { |
87 data->free_failed++; |
89 data->free_failed++; |
88 } |
90 } |
|
91 #pragma GCC diagnostic pop |
89 cx_testing_allocator_track(data, ptr); |
92 cx_testing_allocator_track(data, ptr); |
90 } |
93 } |
91 return ptr; |
94 return ptr; |
92 } |
95 } |
93 } |
96 } |