Commit 8b38d261 authored by serg@serg.mylan's avatar serg@serg.mylan

protect deleted objects from reusal with safemalloc technique

parent bb8b0d9d
......@@ -37,7 +37,11 @@ class Field
void operator=(Field &);
public:
static void *operator new(size_t size) {return (void*) sql_alloc((uint) size); }
static void operator delete(void *ptr_arg, size_t size) {} /*lint -e715 */
static void operator delete(void *ptr_arg, size_t size) {
#ifdef PEDANTIC_SAFEMALLOC
bfill(ptr_arg, size, 0x8F);
#endif
}
char *ptr; // Position to field in record
uchar *null_ptr; // Byte where null_bit is
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment