diff options
author | Nanang Izzuddin <nanang@teluu.com> | 2014-06-19 09:42:02 +0000 |
---|---|---|
committer | Nanang Izzuddin <nanang@teluu.com> | 2014-06-19 09:42:02 +0000 |
commit | 1321a047fb6d74374f7948eda41ad5c84884daab (patch) | |
tree | 3a0bd88b9610bbbe80b1de3351dea390e04058bf /pjlib/include | |
parent | f0d0ddae6055d905cb55b6aebe17f073c52cb383 (diff) |
Fix #1773: Added group lock to SIP transport to avoid race condition between transport callback and destroy.
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@4862 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjlib/include')
-rw-r--r-- | pjlib/include/pj/ssl_sock.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/pjlib/include/pj/ssl_sock.h b/pjlib/include/pj/ssl_sock.h index 23843717..92e86aab 100644 --- a/pjlib/include/pj/ssl_sock.h +++ b/pjlib/include/pj/ssl_sock.h @@ -552,6 +552,11 @@ typedef struct pj_ssl_sock_info */ unsigned long last_native_err; + /** + * Group lock assigned to the ioqueue key. + */ + pj_grp_lock_t *grp_lock; + } pj_ssl_sock_info; @@ -561,6 +566,17 @@ typedef struct pj_ssl_sock_info typedef struct pj_ssl_sock_param { /** + * Optional group lock to be assigned to the ioqueue key. + * + * Note that when a secure socket listener is configured with a group + * lock, any new secure socket of an accepted incoming connection + * will have its own group lock created automatically by the library, + * this group lock can be queried via pj_ssl_sock_get_info() in the info + * field pj_ssl_sock_info::grp_lock. + */ + pj_grp_lock_t *grp_lock; + + /** * Specifies socket address family, either pj_AF_INET() and pj_AF_INET6(). * * Default is pj_AF_INET(). |