Changeset 797 for pjproject/trunk/pjsip/src/pjsip/sip_endpoint.c
- Timestamp:
- Nov 11, 2006 4:16:04 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip/src/pjsip/sip_endpoint.c
r753 r797 319 319 } 320 320 321 322 /* 323 * Check if the specified capability is supported. 324 */ 325 PJ_DEF(pj_bool_t) pjsip_endpt_has_capability( pjsip_endpoint *endpt, 326 int htype, 327 const pj_str_t *hname, 328 const pj_str_t *token) 329 { 330 const pjsip_generic_array_hdr *hdr; 331 unsigned i; 332 333 hdr = (const pjsip_generic_array_hdr*) 334 pjsip_endpt_get_capability(endpt, htype, hname); 335 if (!hdr) 336 return PJ_FALSE; 337 338 PJ_ASSERT_RETURN(token != NULL, PJ_FALSE); 339 340 for (i=0; i<hdr->count; ++i) { 341 if (!pj_stricmp(&hdr->values[i], token)) 342 return PJ_TRUE; 343 } 344 345 return PJ_FALSE; 346 } 321 347 322 348 /*
Note: See TracChangeset
for help on using the changeset viewer.