Changeset 64 for pjproject/trunk/pjsip/src/pjsip/sip_endpoint.c
- Timestamp:
- Nov 20, 2005 7:58:10 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip/src/pjsip/sip_endpoint.c
r57 r64 23 23 #include <pjsip/sip_resolve.h> 24 24 #include <pjsip/sip_module.h> 25 #include <pjsip/sip_ misc.h>25 #include <pjsip/sip_util.h> 26 26 #include <pjsip/sip_errno.h> 27 27 #include <pj/except.h> … … 107 107 108 108 /* 109 * Create transaction.110 * Defined in sip_transaction.c111 */112 pj_status_t pjsip_tsx_create( pj_pool_t *pool, pjsip_endpoint *endpt,113 pjsip_transaction **tsx );114 115 /*116 109 * This is the global handler for memory allocation failure, for pools that 117 110 * are created by the endpoint (by default, all pools ARE allocated by … … 295 288 * Get "Allow" header. 296 289 */ 297 PJ_DE CL(const pjsip_allow_hdr*) pjsip_endpt_get_allow_hdr( pjsip_endpoint *endpt )290 PJ_DEF(const pjsip_allow_hdr*) pjsip_endpt_get_allow_hdr( pjsip_endpoint *endpt ) 298 291 { 299 292 return endpt->allow_hdr; … … 672 665 * Find transaction by the key. 673 666 */ 674 PJ_DE CL(pjsip_transaction*) pjsip_endpt_find_tsx( pjsip_endpoint *endpt,667 PJ_DEF(pjsip_transaction*) pjsip_endpt_find_tsx( pjsip_endpoint *endpt, 675 668 const pj_str_t *key ) 676 669 { … … 981 974 * Find/create transport. 982 975 */ 983 PJ_DE CL(pj_status_t) pjsip_endpt_alloc_transport( pjsip_endpoint *endpt,976 PJ_DEF(pj_status_t) pjsip_endpt_alloc_transport( pjsip_endpoint *endpt, 984 977 pjsip_transport_type_e type, 985 978 const pj_sockaddr_in *remote, … … 992 985 993 986 987 /* 988 * Report error. 989 */ 990 PJ_DEF(void) pjsip_endpt_log_error( pjsip_endpoint *endpt, 991 const char *sender, 992 pj_status_t error_code, 993 const char *format, 994 ... ) 995 { 996 char newformat[256]; 997 int len; 998 va_list marker; 999 1000 va_start(marker, format); 1001 1002 PJ_UNUSED_ARG(endpt); 1003 1004 len = pj_native_strlen(format); 1005 if (len < sizeof(newformat)-30) { 1006 pj_str_t errstr; 1007 1008 pj_native_strcpy(newformat, format); 1009 pj_snprintf(newformat+len, sizeof(newformat)-len-1, 1010 ": [err %d] ", error_code); 1011 len += pj_native_strlen(newformat+len); 1012 1013 errstr = pjsip_strerror(error_code, newformat+len, 1014 sizeof(newformat)-len-1); 1015 1016 len += errstr.slen; 1017 newformat[len] = '\0'; 1018 1019 pj_log(sender, 1, newformat, marker); 1020 } else { 1021 pj_log(sender, 1, format, marker); 1022 } 1023 1024 va_end(marker); 1025 } 1026 1027 1028 /* 1029 * Dump endpoint. 1030 */ 994 1031 PJ_DEF(void) pjsip_endpt_dump( pjsip_endpoint *endpt, pj_bool_t detail ) 995 1032 {
Note: See TracChangeset
for help on using the changeset viewer.