diff options
author | Nanang Izzuddin <nanang@teluu.com> | 2009-08-11 12:42:38 +0000 |
---|---|---|
committer | Nanang Izzuddin <nanang@teluu.com> | 2009-08-11 12:42:38 +0000 |
commit | 6f204c13ce8519524eb4da79359ac9b2aea08252 (patch) | |
tree | fd03248a6aa6c121822cbca2507113cf5b86b0f0 /pjsip-apps/src/python | |
parent | 04fbadef1554da3b61c412e030081d1f05c6a99a (diff) |
Ticket #833:
- Initial version of Session Timers (RFC 4028).
- Added new options in pjsua app to configure Session Timers settings.
- Added python tests for Session Timers.
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@2858 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjsip-apps/src/python')
-rw-r--r-- | pjsip-apps/src/python/_pjsua.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/pjsip-apps/src/python/_pjsua.h b/pjsip-apps/src/python/_pjsua.h index d3958d76..931fcbe6 100644 --- a/pjsip-apps/src/python/_pjsua.h +++ b/pjsip-apps/src/python/_pjsua.h @@ -1656,6 +1656,9 @@ typedef struct PyObject *contact_params; PyObject *contact_uri_params; int require_100rel; + int require_timer; + unsigned timer_se; + unsigned timer_min_se; int allow_contact_rewrite; int ka_interval; PyObject *ka_data; @@ -1730,6 +1733,9 @@ static void PyObj_pjsua_acc_config_import(PyObj_pjsua_acc_config *obj, Py_XDECREF(obj->contact_uri_params); obj->contact_uri_params = PyString_FromPJ(&cfg->contact_uri_params); obj->require_100rel = cfg->require_100rel; + obj->require_timer = cfg->require_timer; + obj->timer_se = cfg->timer_se; + obj->timer_min_se = cfg->timer_min_se; obj->allow_contact_rewrite = cfg->allow_contact_rewrite; obj->ka_interval = cfg->ka_interval; Py_XDECREF(obj->ka_data); @@ -1776,6 +1782,9 @@ static void PyObj_pjsua_acc_config_export(pjsua_acc_config *cfg, cfg->contact_params = PyString_ToPJ(obj->contact_params); cfg->contact_uri_params = PyString_ToPJ(obj->contact_uri_params); cfg->require_100rel = obj->require_100rel; + cfg->require_timer = obj->require_timer; + cfg->timer_se = obj->timer_se; + cfg->timer_min_se = obj->timer_min_se; cfg->allow_contact_rewrite = obj->allow_contact_rewrite; cfg->ka_interval = obj->ka_interval; cfg->ka_data = PyString_ToPJ(obj->ka_data); @@ -1921,6 +1930,21 @@ static PyMemberDef PyObj_pjsua_acc_config_members[] = "Require reliable provisional response." }, { + "require_timer", T_INT, + offsetof(PyObj_pjsua_acc_config, require_timer), 0, + "Require session timer." + }, + { + "timer_se", T_INT, + offsetof(PyObj_pjsua_acc_config, timer_se), 0, + "Session timer expiration period, in seconds." + }, + { + "timer_min_se", T_INT, + offsetof(PyObj_pjsua_acc_config, timer_min_se), 0, + "Session timer minimum expiration period, in seconds." + }, + { "allow_contact_rewrite", T_INT, offsetof(PyObj_pjsua_acc_config, allow_contact_rewrite), 0, "Re-REGISTER if behind symmetric NAT." |