Module: sip-router Branch: henning/trie Commit: f34610e3ec970664efab940592dd2cbd0f48260b URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=f34610e3...
Author: Henning Westerholt henning.westerholt@1und1.de Committer: Henning Westerholt henning.westerholt@1und1.de Date: Fri Nov 21 13:23:02 2008 +0100
add SHM_MEM_ERROR and PKG_MEM_ERROR logging macros to mem.h
---
mem/mem.h | 9 +++++++++ 1 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/mem/mem.h b/mem/mem.h index 8ba35b5..7cb79a8 100644 --- a/mem/mem.h +++ b/mem/mem.h @@ -152,4 +152,13 @@ int init_pkg_mallocs(); int init_shm_mallocs(int force_alloc);
+/*! generic logging helper for allocation errors in private memory pool/ system */ +#ifdef SYSTEM_MALLOC +#define PKG_MEM_ERROR LM_ERR("could not allocate private memory from system") +#else +#define PKG_MEM_ERROR LM_ERR("could not allocate private memory from available pool") +#endif +/*! generic logging helper for allocation errors in shared memory pool */ +#define SHM_MEM_ERROR LM_ERR("could not allocate shared memory from available pool") + #endif