- Timestamp:
- Feb 23, 2006 6:03:29 PM (19 years ago)
- Location:
- pjproject/trunk/pjsip/src/pjsua
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip/src/pjsua/main.c
r222 r226 345 345 continue; 346 346 347 /* 348 * Must check again! 349 * Call may have been disconnected while we're waiting for 350 * keyboard input. 351 */ 352 if (inv_session == &pjsua.inv_list) { 353 puts("Call has been disconnected"); 354 fflush(stdout); 355 continue; 356 } 357 347 358 status = pjsip_inv_answer(inv_session->inv, atoi(buf), 348 359 NULL, NULL, &tdata); … … 440 451 441 452 } else { 453 struct pjsua_inv_data *cur = inv_session; 454 442 455 ui_input_url("Transfer to URL", buf, sizeof(buf), &result); 456 457 /* Check if call is still there. */ 458 459 if (cur != inv_session) { 460 puts("Call has been disconnected"); 461 continue; 462 } 463 443 464 if (result.nb_result != NO_NB) { 444 465 if (result.nb_result == -1) … … 468 489 } else { 469 490 pj_str_t digits; 491 struct pjsua_inv_data *cur = inv_session; 470 492 pj_status_t status; 471 493 472 494 if (!simple_input("DTMF strings to send (0-9*#A-B)", buf, 473 495 sizeof(buf))) 496 { 474 497 break; 498 } 499 500 if (cur != inv_session) { 501 puts("Call has been disconnected"); 502 continue; 503 } 475 504 476 505 digits = pj_str(buf); -
pjproject/trunk/pjsip/src/pjsua/pjsua_inv.c
r223 r226 122 122 123 123 124 /* Add invite session to the list. */ 125 126 pj_list_push_back(&pjsua.inv_list, inv_data); 127 128 124 129 /* Send initial INVITE: */ 125 130 126 131 status = pjsip_inv_send_msg(inv, tdata, NULL); 127 132 if (status != PJ_SUCCESS) { 133 /* 134 * Note: 135 * inv_data will be removed from the list in the callback 136 */ 128 137 pjsua_perror(THIS_FILE, "Unable to send initial INVITE request", 129 138 status); 130 139 goto on_error; 131 140 } 132 133 /* Add invite session to the list. */134 135 pj_list_push_back(&pjsua.inv_list, inv_data);136 141 137 142
Note: See TracChangeset
for help on using the changeset viewer.