From 8e38c03c361f1aa03e7226dcbcf1ae42615805a1 Mon Sep 17 00:00:00 2001 From: mmichelson Date: Tue, 18 Nov 2008 22:15:31 +0000 Subject: Once again, Russell to the rescue. Use the builtin astobj1 lock of the sip_peer and sip_user instead of adding a new one git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@157501 f38db490-d61c-443f-a65b-d21fe96a405b --- channels/chan_sip.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'channels') diff --git a/channels/chan_sip.c b/channels/chan_sip.c index 379f872b7..6a55c65f1 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -1416,7 +1416,6 @@ struct sip_user { int maxcallbitrate; /*!< Maximum Bitrate for a video call */ int autoframing; struct sip_st_cfg stimer; /*!< SIP Session-Timers */ - ast_mutex_t lock; }; /*! @@ -1510,7 +1509,6 @@ struct sip_peer { int timer_t1; /*!< The maximum T1 value for the peer */ int timer_b; /*!< The maximum timer B (transaction timeouts) */ int deprecated_username; /*!< If it's a realtime peer, are they using the deprecated "username" instead of "defaultuser" */ - ast_mutex_t lock; }; @@ -4506,13 +4504,13 @@ static int update_call_counter(struct sip_pvt *fup, int event) inuse = &u->inUse; call_limit = &u->call_limit; inringing = NULL; - pu_lock = &u->lock; + pu_lock = &u->_lock; } else if ( (p = find_peer(ast_strlen_zero(fup->peername) ? name : fup->peername, NULL, 1, 0) ) ) { /* Try to find peer */ inuse = &p->inUse; call_limit = &p->call_limit; inringing = &p->inRinging; ast_copy_string(name, fup->peername, sizeof(name)); - pu_lock = &p->lock; + pu_lock = &p->_lock; } if (!p && !u) { ast_debug(2, "%s is not a local device, no call limit\n", name); -- cgit v1.2.3