]> tinc-vpn.org Git - tinc/blobdiff - src/have.h
Improve use of compiler attributes
[tinc] / src / have.h
index d176098fd62152059b6b03a2c97e150981391852..a155b04b41abe7a94f106bc8430b52fac6cb8914 100644 (file)
 #endif
 #endif
 
+#if defined(HAVE_ATTR_MALLOC_WITH_ARG)
+#define ATTR_DEALLOCATOR(dealloc) __attribute__((__malloc__(dealloc)))
+#else
+#define ATTR_DEALLOCATOR(dealloc)
+#endif
+
 #ifdef HAVE_ATTR_MALLOC
 #define ATTR_MALLOC __attribute__((__malloc__))
 #else