diff options
author | Richard Mudgett <rmudgett@digium.com> | 2012-02-24 18:33:04 +0000 |
---|---|---|
committer | Richard Mudgett <rmudgett@digium.com> | 2012-02-24 18:33:04 +0000 |
commit | ebe2c33b7239b2881007efa3efd8d8a859f0b653 (patch) | |
tree | 1ea2be16f26726b316809648cdd7f71fe24239ba /include/asterisk | |
parent | 8e1f841dde99b00e0581e8d5f2859bc503d70aed (diff) |
Fix worker thread resource leak in SIP TCP/TLS.
The SIP TCP/TLS worker threads were created joinable but noone could join
them if they died on their own.
* Fix the SIP TCP/TLS worker threads to not be created joinable.
* _sip_tcp_helper_thread() only needs one parameter since the pvt
parameter is only passed in as NULL and never used.
(closes issue ASTERISK-19203)
Reported by: Steve Davies
Review: https://reviewboard.asterisk.org/r/1714/
........
Merged revisions 356677 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........
Merged revisions 356690 from http://svn.asterisk.org/svn/asterisk/branches/10
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@356697 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'include/asterisk')
-rw-r--r-- | include/asterisk/tcptls.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/asterisk/tcptls.h b/include/asterisk/tcptls.h index e9b2371fb..c60501397 100644 --- a/include/asterisk/tcptls.h +++ b/include/asterisk/tcptls.h @@ -136,6 +136,7 @@ struct ast_tcptls_session_args { struct ast_tls_config *tls_cfg; /*!< points to the SSL configuration if any */ int accept_fd; int poll_timeout; + /*! Server accept_fn thread ID used for external shutdown requests. */ pthread_t master; void *(*accept_fn)(void *); /*!< the function in charge of doing the accept */ void (*periodic_fn)(void *);/*!< something we may want to run before after select on the accept socket */ @@ -154,6 +155,7 @@ struct ast_tcptls_session_instance { int client; struct ast_sockaddr remote_address; struct ast_tcptls_session_args *parent; + /*! \todo XXX Why do we still use this lock when this struct is allocated as an ao2 object which has its own lock? */ ast_mutex_t lock; }; |