summaryrefslogtreecommitdiff
path: root/pjlib/include/pj/ioqueue.h
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2013-02-21 11:18:36 +0000
committerBenny Prijono <bennylp@teluu.com>2013-02-21 11:18:36 +0000
commit9b8e0a5afe9cba0fd430e9642630bd465db9aefa (patch)
tree550cd346c99b144a79c76096dc75d6be2dfb3c31 /pjlib/include/pj/ioqueue.h
parent99de12689e7c6b8117ee82ff8e3c17e5ec85418d (diff)
Fixed #1616: Implementation of Group lock and other foundation in PJLIB for fixing synchronization issues
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@4359 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjlib/include/pj/ioqueue.h')
-rw-r--r--pjlib/include/pj/ioqueue.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/pjlib/include/pj/ioqueue.h b/pjlib/include/pj/ioqueue.h
index 40bb403c..1e983327 100644
--- a/pjlib/include/pj/ioqueue.h
+++ b/pjlib/include/pj/ioqueue.h
@@ -405,6 +405,19 @@ PJ_DECL(pj_status_t) pj_ioqueue_register_sock( pj_pool_t *pool,
pj_ioqueue_key_t **key );
/**
+ * Variant of pj_ioqueue_register_sock() with additional group lock parameter.
+ * If group lock is set for the key, the key will add the reference counter
+ * when the socket is registered and decrease it when it is destroyed.
+ */
+PJ_DECL(pj_status_t) pj_ioqueue_register_sock2(pj_pool_t *pool,
+ pj_ioqueue_t *ioque,
+ pj_sock_t sock,
+ pj_grp_lock_t *grp_lock,
+ void *user_data,
+ const pj_ioqueue_callback *cb,
+ pj_ioqueue_key_t **key );
+
+/**
* Unregister from the I/O Queue framework. Caller must make sure that
* the key doesn't have any pending operations before calling this function,
* by calling #pj_ioqueue_is_pending() for all previously submitted