]>
git.ipfire.org Git - thirdparty/squid.git/blob - src/LeakFinder.h
2 * Copyright (C) 1996-2014 The Squid Software Foundation and contributors
4 * Squid software is distributed under GPLv2+ license and includes
5 * contributions from numerous individuals and organizations.
6 * Please see the COPYING and CONTRIBUTORS files for details.
9 #ifndef SQUID_LEAKFINDER_H
10 #define SQUID_LEAKFINDER_H
16 #define leakAdd(p,l) if (l) l->addSome(p,__FILE__,__LINE__)
17 #define leakTouch(p,l) if (l) l->touch(p,__FILE__,__LINE__)
18 #define leakFree(p,l) if (l) l->freeSome(p,__FILE__,__LINE__)
20 class LeakFinderPtr
: public hash_link
24 LeakFinderPtr(void *, const char *, const int);
37 void *addSome(void *, const char *, const int);
39 void *touch(void *, const char *, const int);
41 void *freeSome(void *, const char *, const int);
58 #else /* USE_LEAKFINDER */
62 #define leakAdd(p,l) (void)0
63 #define leakTouch(p,l) (void)0
64 #define leakFree(p,l) (void)0
65 #endif /* USE_LEAKFINDER */
67 #endif /* SQUID_LEAKFINDER_H */