blob: 29bb2aaf320776365b0a335003f2c5d0c5bb2768 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
/* See LICENSE file for copyright and license details. */
#include "common.h"
#ifndef TEST
void
libtest_stop_tracking(void)
{
libtest_malloc_accept_leakage = 1;
}
#else
int
main(void)
{
SET_UP_ALARM();
EXPECT(libtest_malloc_accept_leakage == 1);
libtest_malloc_accept_leakage = 0;
EXPECT(libtest_malloc_accept_leakage == 0);
libtest_stop_tracking();
EXPECT(libtest_malloc_accept_leakage == 1);
return 0;
}
#endif
|