- add AST_LIST_HEAD_NOLOCK_STATIC, similar to AST_LIST_HEAD_STATIC, but without the lock!

- store registered channel backends using linked list macros


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@7968 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Russell Bryant
2006-01-11 05:05:13 +00:00
parent e0d4fcfb55
commit 752e3c8938
2 changed files with 34 additions and 27 deletions

View File

@@ -128,6 +128,20 @@ struct name { \
.lock = AST_MUTEX_INIT_VALUE, \
};
/*!
\brief Defines a structure to be used to hold a list of specified type, statically initialized.
This is the same as AST_LIST_HEAD_STATIC, except without the lock included.
*/
#define AST_LIST_HEAD_NOLOCK_STATIC(name, type) \
struct name { \
struct type *first; \
struct type *last; \
} name = { \
.first = NULL, \
.last = NULL, \
};
/*!
\brief Initializes a list head structure with a specified first entry.
\param head This is a pointer to the list head structure