Commit 869e112f authored by Augustin Degomme's avatar Augustin Degomme

rename this macro.

It's actually useful outside of sampi, to disable malloc override when it conflicts with other codes and is not needed.
Fors instance FFTW uses FFTW(malloc(x)) to actually call fftw_malloc, and our macro was then breaking compilation.
parent c16e6542
Pipeline #191837 passed with stages
in 24 minutes and 2 seconds
......@@ -6,7 +6,7 @@
#ifndef SAMPI_H_
#define SAMPI_H_
#define SAMPI_OVERRIDEN_MALLOC
#define SMPI_NO_OVERRIDE_MALLOC
#include <stdlib.h>
#include <smpi/smpi.h>
......
......@@ -32,7 +32,7 @@
#define getopt(x, y, z) smpi_getopt((x), (y), (z))
#define getopt_long(x, y, z, a, b) smpi_getopt_long((x), (y), (z), (a), (b))
#define getopt_long_only(x, y, z, a, b) smpi_getopt_long_only((x), (y), (z), (a), (b))
#ifndef SAMPI_OVERRIDEN_MALLOC
#ifndef SMPI_NO_OVERRIDE_MALLOC
#define malloc(x) smpi_shared_malloc_intercept(x, __FILE__, __LINE__)
#define calloc(x,y) smpi_shared_calloc_intercept(x,y, __FILE__, __LINE__)
#define free(x) smpi_shared_free(x)
......
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