Disable multiple registrations on a per-device basis (MODENDP-117)

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@9042 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Michael Jerris
2008-07-15 18:04:17 +00:00
parent 56d2b38e69
commit 4d2cbfe197
2 changed files with 35 additions and 2 deletions
+16
View File
@@ -104,6 +104,22 @@ SWITCH_DECLARE(switch_size_t) switch_fd_read_line(int fd, char *buf, switch_size
!strcasecmp(expr, "active") ||\
!strcasecmp(expr, "allow") ||\
atoi(expr))) ? SWITCH_TRUE : SWITCH_FALSE
/*!
\brief Evaluate the falsefullness of a string expression
\param expr a string expression
\return true or false
*/
#define switch_false(expr)\
(expr && ( !strcasecmp(expr, "no") ||\
!strcasecmp(expr, "off") ||\
!strcasecmp(expr, "false") ||\
!strcasecmp(expr, "disabled") ||\
!strcasecmp(expr, "inactive") ||\
!strcasecmp(expr, "disallow") ||\
!atoi(expr))) ? SWITCH_TRUE : SWITCH_FALSE
/*!
\brief find local ip of the box
\param buf the buffer to write the ip adress found into