diff options
author | igor@rurik.mysql.com <> | 2004-02-19 01:09:54 -0800 |
---|---|---|
committer | igor@rurik.mysql.com <> | 2004-02-19 01:09:54 -0800 |
commit | f18e0068ba81c909b28ed4b66ee6d84f7e4ad932 (patch) | |
tree | aa627335f475f099e0d352b39af4e24d6e1ac189 /sql/sql_list.h | |
parent | 09fa16424a9d5e35b1b7abbc912b0bdfc105f15f (diff) | |
parent | 1be033f62cc7decdc0867ad44aaebd87b3f74884 (diff) | |
download | mariadb-git-f18e0068ba81c909b28ed4b66ee6d84f7e4ad932.tar.gz |
Manual merge
Diffstat (limited to 'sql/sql_list.h')
-rw-r--r-- | sql/sql_list.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/sql/sql_list.h b/sql/sql_list.h index 5318237b786..e8b15974924 100644 --- a/sql/sql_list.h +++ b/sql/sql_list.h @@ -21,6 +21,12 @@ /* mysql standard class memoryallocator */ +#ifdef PEDANTIC_SAFEMALLOC +#define TRASH(XX,YY) bfill((XX), (YY), 0x8F) +#else +#define TRASH(XX,YY) /* no-op */ +#endif + class Sql_alloc { public: @@ -34,8 +40,8 @@ public: } static void *operator new(size_t size, MEM_ROOT *mem_root) { return (void*) alloc_root(mem_root, (uint) size); } - static void operator delete(void *ptr, size_t size) {} /*lint -e715 */ - static void operator delete[](void *ptr, size_t size) {} + static void operator delete(void *ptr, size_t size) { TRASH(ptr, size); } + static void operator delete[](void *ptr, size_t size) { TRASH(ptr, size); } #ifdef HAVE_purify bool dummy; inline Sql_alloc() :dummy(0) {} |