Changeset 364:e1b6bfaba51c in verona
- Timestamp:
- Nov 8, 2011 3:40:01 PM (19 months ago)
- Branch:
- default
- File:
-
- 1 edited
-
phapi/phapi.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
phapi/phapi.c
r358 r364 121 121 122 122 123 static char *ph_get_call_(phcall_t *ca); 124 static void set_customized_header(osip_message_t *req, const char *h, const char *v); 123 125 static char *ph_get_call_contact(phcall_t *ca); 124 static void set_customized_header(osip_message_t *req, const char *h, const char *v);125 126 126 127 #define MEDIA_SUSPEND … … 6141 6142 static int ph_find_expires_for_vl(int vlid, osip_message_t *msg) 6142 6143 { 6143 //TODO: we must every Contact header field and extracting the value of "expires" param, 6144 //currently let's return 0 so phapi will keep the vline regTimeout 6145 return 0; 6144 osip_contact_t* mctct; 6145 osip_contact_t* lctct; 6146 struct vline *vl; 6147 int ret = 0; 6148 int pos = 0; 6149 6150 osip_contact_init(&lctct); 6151 osip_contact_parse(lctct, vl->contact); 6152 6153 vl = vl = ph_valid_vlid(vlid); 6154 if (!vl) 6155 return 0; 6156 6157 while(!osip_message_get_contact(msg, pos++, &mctct)) { 6158 osip_uri_param_t *param; 6159 6160 ret = ph_same_str(lctct->url->username, mctct->url->username) && 6161 ph_same_str(lctct->url->host, mctct->url->host) && 6162 ph_same_str(lctct->url->port, mctct->url->port); 6163 if (!ret) 6164 continue; 6165 6166 ret = 0; 6167 if (!osip_contact_param_get_byname(mctct, "Expires", ¶m)) { 6168 ret = atoi(param->gvalue); 6169 } 6170 break; 6171 } 6172 osip_contact_free(lctct); 6173 return ret; 6146 6174 } 6147 6175
Note: See TracChangeset
for help on using the changeset viewer.
