mirror of
https://github.com/MariaDB/server.git
synced 2025-08-20 18:30:51 +00:00

- Fixed compiler errors - Modified Makefiles to be part of plugin directory - Some minor changes in database.cpp to use the new MariaDB handler interface
38 lines
763 B
C++
38 lines
763 B
C++
|
|
// vim:sw=2:ai
|
|
|
|
/*
|
|
* Copyright (C) 2010 DeNA Co.,Ltd.. All rights reserved.
|
|
* See COPYRIGHT.txt for details.
|
|
*/
|
|
|
|
#ifndef DENA_ALLOCATOR_HPP
|
|
#define DENA_ALLOCATOR_HPP
|
|
|
|
#include <stdlib.h>
|
|
#include <string.h>
|
|
|
|
#if 0
|
|
extern "C" {
|
|
#include <tlsf.h>
|
|
};
|
|
#define DENA_MALLOC(x) tlsf_malloc(x)
|
|
#define DENA_REALLOC(x, y) tlsf_realloc(x, y)
|
|
#define DENA_FREE(x) tlsf_free(x)
|
|
#define DENA_NEWCHAR(x) static_cast<char *>(tlsf_malloc(x))
|
|
#define DENA_DELETE(x) tlsf_free(x)
|
|
typedef std::allocator<int> allocator_type;
|
|
#endif
|
|
|
|
#if 1
|
|
#define DENA_MALLOC(x) malloc(x)
|
|
#define DENA_REALLOC(x, y) realloc(x, y)
|
|
#define DENA_FREE(x) free(x)
|
|
#define DENA_NEWCHAR(x) (new char[x])
|
|
#define DENA_DELETE(x) (delete [] x)
|
|
typedef std::allocator<int> allocator_type;
|
|
#endif
|
|
|
|
#endif
|
|
|