From 72b5354cb56d4abfbb5d31beb8dad359c5396328 Mon Sep 17 00:00:00 2001 From: Michael Davidsaver Date: Tue, 8 Feb 2011 13:28:02 -0500 Subject: [PATCH] CDRMonitor: NDEBUG --- pvDataApp/misc/CDRMonitor.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/pvDataApp/misc/CDRMonitor.h b/pvDataApp/misc/CDRMonitor.h index 924de2f..7f11b4b 100644 --- a/pvDataApp/misc/CDRMonitor.h +++ b/pvDataApp/misc/CDRMonitor.h @@ -102,6 +102,8 @@ getNode(CDRNodeInstance *inst) return inst->node; } +#ifndef NDEBUG + #define PVDATA_REFCOUNT_MONITOR_DEFINE(NAME) \ static CDRNodeInstance NAME ## _node={0,EPICS_THREAD_ONCE_INIT,#NAME} @@ -117,5 +119,15 @@ static CDRNodeInstance NAME ## _node={0,EPICS_THREAD_ONCE_INIT,#NAME} getNode(&NAME ## _node)->decRef() +#else + +#define PVDATA_REFCOUNT_MONITOR_DEFINE(NAME) +#define PVDATA_REFCOUNT_MONITOR_DESTRUCT(NAME) +#define PVDATA_REFCOUNT_MONITOR_CONSTRUCT(NAME) +#define PVDATA_REFCOUNT_MONITOR_INCREF(NAME) +#define PVDATA_REFCOUNT_MONITOR_DECREF(NAME) + +#endif + }} #endif /* CDRMONITOR_H */