Changeset 995 for pjproject/trunk/pjsip-apps/src/pjsua/pjsua_app.c
- Timestamp:
- Feb 22, 2007 2:52:24 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip-apps/src/pjsua/pjsua_app.c
r974 r995 2285 2285 2286 2286 } else { 2287 int st_code; 2288 char contact[120]; 2289 pj_str_t hname = { "Contact", 7 }; 2290 pj_str_t hvalue; 2291 pjsip_generic_string_hdr hcontact; 2292 pjsua_msg_data msg_data; 2293 2287 2294 if (!simple_input("Answer with code (100-699)", buf, sizeof(buf))) 2288 2295 continue; 2289 2296 2290 if (my_atoi(buf) < 100) 2297 st_code = my_atoi(buf); 2298 if (st_code < 100) 2291 2299 continue; 2300 2301 pjsua_msg_data_init(&msg_data); 2302 2303 if (st_code/100 == 3) { 2304 if (!simple_input("Enter URL to be put in Contact", 2305 contact, sizeof(contact))) 2306 continue; 2307 hvalue = pj_str(contact); 2308 pjsip_generic_string_hdr_init2(&hcontact, &hname, &hvalue); 2309 2310 pj_list_push_back(&msg_data.hdr_list, &hcontact); 2311 } 2292 2312 2293 2313 /* … … 2302 2322 } 2303 2323 2304 pjsua_call_answer(current_call, my_atoi(buf), NULL, NULL);2324 pjsua_call_answer(current_call, st_code, NULL, &msg_data); 2305 2325 } 2306 2326
Note: See TracChangeset
for help on using the changeset viewer.