Changeset 3753 for pjproject/trunk/pjsip/src/pjsua-lib/pjsua_media.c
- Timestamp:
- Sep 18, 2011 2:59:56 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip/src/pjsua-lib/pjsua_media.c
r3714 r3753 73 73 PJ_UNUSED_ARG(codec_id); 74 74 75 pj_log_push_indent(); 76 75 77 /* Specify which audio device settings are save-able */ 76 78 pjsua_var.aud_svmask = 0xFFFFFFFF; … … 111 113 "Media stack initialization has returned error", 112 114 status); 113 return status;115 goto on_error; 114 116 } 115 117 … … 138 140 pjsua_perror(THIS_FILE, "Error querying audio device info", 139 141 status); 140 return status;142 goto on_error; 141 143 } 142 144 … … 175 177 if (status != PJ_SUCCESS) { 176 178 PJ_PERROR(1,(THIS_FILE, status, "Error registering codecs")); 177 return status;179 goto on_error; 178 180 } 179 181 … … 229 231 pjsua_perror(THIS_FILE, "Error creating conference bridge", 230 232 status); 231 return status;233 goto on_error; 232 234 } 233 235 … … 251 253 pjsua_perror(THIS_FILE, "Error initializing SRTP library", 252 254 status); 253 return status;255 goto on_error; 254 256 } 255 257 #endif … … 259 261 status = pjsua_vid_subsys_init(); 260 262 if (status != PJ_SUCCESS) 261 return status;263 goto on_error; 262 264 #endif 263 265 266 pj_log_pop_indent(); 264 267 return PJ_SUCCESS; 268 269 on_error: 270 pj_log_pop_indent(); 271 return status; 265 272 } 266 273 … … 345 352 pj_status_t status; 346 353 354 pj_log_push_indent(); 355 347 356 #if DISABLED_FOR_TICKET_1185 348 357 /* Create media for calls, if none is specified */ … … 355 364 356 365 status = pjsua_media_transports_create(&transport_cfg); 357 if (status != PJ_SUCCESS) 366 if (status != PJ_SUCCESS) { 367 pj_log_pop_indent(); 358 368 return status; 369 } 359 370 } 360 371 #endif … … 366 377 #if PJMEDIA_HAS_VIDEO 367 378 status = pjsua_vid_subsys_start(); 368 if (status != PJ_SUCCESS) 379 if (status != PJ_SUCCESS) { 380 pj_log_pop_indent(); 369 381 return status; 382 } 370 383 #endif 371 384 … … 376 389 } 377 390 391 pj_log_pop_indent(); 378 392 return PJ_SUCCESS; 379 393 } … … 388 402 389 403 PJ_LOG(4,(THIS_FILE, "Shutting down media..")); 404 pj_log_push_indent(); 390 405 391 406 close_snd_dev(); … … 451 466 /* Reset RTP port */ 452 467 next_rtp_port = 0; 468 469 pj_log_pop_indent(); 453 470 454 471 return PJ_SUCCESS; … … 1364 1381 return PJ_EBUSY; 1365 1382 1383 PJ_LOG(4,(THIS_FILE, "Call %d: initializing media..", call_id)); 1384 pj_log_push_indent(); 1385 1366 1386 #if DISABLED_FOR_TICKET_1185 1367 1387 /* Return error if media transport has not been created yet … … 1370 1390 for (i=0; i<call->med_cnt; ++i) { 1371 1391 if (call->media[i].tp == NULL) { 1372 return PJ_EBUSY; 1392 status = PJ_EBUSY; 1393 goto on_error; 1373 1394 } 1374 1395 } … … 1386 1407 if (sip_err_code) *sip_err_code = PJSIP_SC_NOT_ACCEPTABLE_HERE; 1387 1408 pjsua_media_channel_deinit(call_id); 1388 return PJSIP_ERRNO_FROM_SIP_STATUS(PJSIP_SC_NOT_ACCEPTABLE_HERE); 1409 status = PJSIP_ERRNO_FROM_SIP_STATUS(PJSIP_SC_NOT_ACCEPTABLE_HERE); 1410 goto on_error; 1389 1411 } 1390 1412 … … 1426 1448 if (sip_err_code) *sip_err_code = PJSIP_SC_NOT_ACCEPTABLE_HERE; 1427 1449 pjsua_media_channel_deinit(call_id); 1428 return PJSIP_ERRNO_FROM_SIP_STATUS(PJSIP_SC_NOT_ACCEPTABLE_HERE); 1450 status = PJSIP_ERRNO_FROM_SIP_STATUS(PJSIP_SC_NOT_ACCEPTABLE_HERE); 1451 goto on_error; 1429 1452 } 1430 1453 … … 1463 1486 if (status != PJ_SUCCESS) { 1464 1487 pjsua_media_channel_deinit(call_id); 1465 return status;1488 goto on_error; 1466 1489 } 1467 1490 } else { … … 1501 1524 if (sip_err_code) *sip_err_code = PJSIP_SC_NOT_ACCEPTABLE; 1502 1525 pjsua_media_channel_deinit(call_id); 1503 return status;1526 goto on_error; 1504 1527 } 1505 1528 … … 1508 1531 } 1509 1532 1533 pj_log_pop_indent(); 1510 1534 return PJ_SUCCESS; 1535 1536 on_error: 1537 pj_log_pop_indent(); 1538 return status; 1511 1539 } 1512 1540 … … 1791 1819 unsigned mi; 1792 1820 1821 pj_log_push_indent(); 1822 1793 1823 for (mi=0; mi<call->med_cnt; ++mi) { 1794 1824 pjsua_call_media *call_med = &call->media[mi]; … … 1839 1869 call_med->state = PJSUA_CALL_MEDIA_NONE; 1840 1870 } 1871 1872 pj_log_pop_indent(); 1841 1873 } 1842 1874 … … 1845 1877 pjsua_call *call = &pjsua_var.calls[call_id]; 1846 1878 unsigned mi; 1879 1880 PJ_LOG(4,(THIS_FILE, "Call %d: deinitializing media..", call_id)); 1881 pj_log_push_indent(); 1847 1882 1848 1883 stop_media_session(call_id); … … 1869 1904 1870 1905 check_snd_dev_idle(); 1906 pj_log_pop_indent(); 1871 1907 1872 1908 return PJ_SUCCESS; … … 1881 1917 { 1882 1918 PJ_UNUSED_ARG(strm); 1919 1920 pj_log_push_indent(); 1883 1921 1884 1922 /* For discussions about call mutex protection related to this … … 1892 1930 pjsua_var.ua_cfg.cb.on_dtmf_digit(call_id, digit); 1893 1931 } 1932 1933 pj_log_pop_indent(); 1894 1934 } 1895 1935 … … 1905 1945 unsigned strm_idx = call_med->idx; 1906 1946 pj_status_t status; 1947 1948 PJ_LOG(4,(THIS_FILE,"Audio channel update..")); 1949 pj_log_push_indent(); 1907 1950 1908 1951 status = pjmedia_stream_info_from_sdp(si, tmp_pool, pjsua_var.med_endpt, 1909 1952 local_sdp, remote_sdp, strm_idx); 1910 1953 if (status != PJ_SUCCESS) 1911 return status;1954 goto on_return; 1912 1955 1913 1956 /* Check if no media is active */ … … 1927 1970 remote_sdp, strm_idx); 1928 1971 if (status != PJ_SUCCESS) 1929 return status;1972 goto on_return; 1930 1973 1931 1974 call_med->tp_st = PJSUA_MED_TP_RUNNING; … … 1992 2035 &call_med->strm.a.stream); 1993 2036 if (status != PJ_SUCCESS) { 1994 return status;2037 goto on_return; 1995 2038 } 1996 2039 … … 1998 2041 status = pjmedia_stream_start(call_med->strm.a.stream); 1999 2042 if (status != PJ_SUCCESS) { 2000 return status;2043 goto on_return; 2001 2044 } 2002 2045 … … 2046 2089 &call_med->strm.a.conf_slot); 2047 2090 if (status != PJ_SUCCESS) { 2048 return status;2091 goto on_return; 2049 2092 } 2050 2093 } … … 2093 2136 if (len > 0) 2094 2137 info_len += len; 2095 PJ_LOG(4,(THIS_FILE,"Media updates%s", info)); 2096 } 2097 2098 return PJ_SUCCESS; 2138 PJ_LOG(4,(THIS_FILE,"Audio updated%s", info)); 2139 } 2140 2141 on_return: 2142 pj_log_pop_indent(); 2143 return status; 2099 2144 } 2100 2145 … … 2120 2165 if (pjsua_get_state() != PJSUA_STATE_RUNNING) 2121 2166 return PJ_EBUSY; 2167 2168 PJ_LOG(4,(THIS_FILE, "Call %d: updating media..", call_id)); 2169 pj_log_push_indent(); 2122 2170 2123 2171 /* Destroy existing media session, if any. */ … … 2183 2231 PJ_LOG(1,(THIS_FILE, "Error updating media for call %d: " 2184 2232 "invalid media index %d in SDP", call_id, mi)); 2185 return PJMEDIA_SDP_EINSDP; 2233 status = PJMEDIA_SDP_EINSDP; 2234 goto on_error; 2186 2235 #endif 2187 2236 } … … 2236 2285 status = pjmedia_sdp_neg_set_remote_offer(tmp_pool, neg, remote_sdp); 2237 2286 if (status != PJ_SUCCESS) 2238 return status;2287 goto on_error; 2239 2288 2240 2289 status = pjmedia_sdp_neg_set_local_answer(tmp_pool, neg, local_sdp); 2241 2290 if (status != PJ_SUCCESS) 2242 return status;2291 goto on_error; 2243 2292 2244 2293 status = pjmedia_sdp_neg_negotiate(tmp_pool, neg, 0); 2245 2294 if (status != PJ_SUCCESS) 2246 return status; 2247 } 2248 2295 goto on_error; 2296 } 2297 2298 pj_log_pop_indent(); 2249 2299 return (got_media? PJ_SUCCESS : PJMEDIA_SDPNEG_ENOMEDIA); 2300 2301 on_error: 2302 pj_log_pop_indent(); 2303 return status; 2250 2304 } 2251 2305 … … 2358 2412 pjsua_conf_port_id sink) 2359 2413 { 2414 pj_status_t status = PJ_SUCCESS; 2415 2416 PJ_LOG(4,(THIS_FILE, "%s connect: %d --> %d", 2417 (pjsua_var.is_mswitch ? "Switch" : "Conf"), 2418 source, sink)); 2419 pj_log_push_indent(); 2420 2360 2421 /* If sound device idle timer is active, cancel it first. */ 2361 2422 PJSUA_LOCK(); … … 2378 2439 unsigned peer_id; 2379 2440 pj_bool_t need_reopen = PJ_FALSE; 2380 pj_status_t status;2381 2441 2382 2442 peer_id = (source!=0)? source : sink; … … 2420 2480 pjsua_perror(THIS_FILE, "Error opening sound device", 2421 2481 status); 2422 return status;2482 goto on_return; 2423 2483 } 2424 2484 … … 2434 2494 pjsua_perror(THIS_FILE, "Error opening sound device", 2435 2495 status); 2436 return status;2496 goto on_return; 2437 2497 } 2438 2498 } else { … … 2443 2503 pjsua_perror(THIS_FILE, "Error opening sound device", 2444 2504 status); 2445 return status;2505 goto on_return; 2446 2506 } 2447 2507 } … … 2468 2528 if (status != PJ_SUCCESS) { 2469 2529 pjsua_perror(THIS_FILE, "Error opening sound device", status); 2470 return status;2530 goto on_return; 2471 2531 } 2472 2532 } else if (pjsua_var.no_snd && !pjsua_var.snd_is_on) { … … 2479 2539 } 2480 2540 2481 return pjmedia_conf_connect_port(pjsua_var.mconf, source, sink, 0); 2541 status = pjmedia_conf_connect_port(pjsua_var.mconf, source, sink, 0); 2542 2543 on_return: 2544 pj_log_pop_indent(); 2545 return status; 2482 2546 } 2483 2547 … … 2491 2555 pj_status_t status; 2492 2556 2557 PJ_LOG(4,(THIS_FILE, "%s disconnect: %d -x- %d", 2558 (pjsua_var.is_mswitch ? "Switch" : "Conf"), 2559 source, sink)); 2560 pj_log_push_indent(); 2561 2493 2562 status = pjmedia_conf_disconnect_port(pjsua_var.mconf, source, sink); 2494 2563 check_snd_dev_idle(); 2495 2564 2565 pj_log_pop_indent(); 2496 2566 return status; 2497 2567 } … … 2559 2629 unsigned slot, file_id; 2560 2630 char path[PJ_MAXPATH]; 2561 pj_pool_t *pool ;2631 pj_pool_t *pool = NULL; 2562 2632 pjmedia_port *port; 2563 pj_status_t status ;2633 pj_status_t status = PJ_SUCCESS; 2564 2634 2565 2635 if (pjsua_var.player_cnt >= PJ_ARRAY_SIZE(pjsua_var.player)) 2566 2636 return PJ_ETOOMANY; 2637 2638 PJ_LOG(4,(THIS_FILE, "Creating file player: %.*s..", 2639 (int)filename->slen, filename->ptr)); 2640 pj_log_push_indent(); 2567 2641 2568 2642 PJSUA_LOCK(); … … 2575 2649 if (file_id == PJ_ARRAY_SIZE(pjsua_var.player)) { 2576 2650 /* This is unexpected */ 2577 PJSUA_UNLOCK();2578 2651 pj_assert(0); 2579 return PJ_EBUG; 2652 status = PJ_EBUG; 2653 goto on_error; 2580 2654 } 2581 2655 … … 2585 2659 pool = pjsua_pool_create(get_basename(path, filename->slen), 1000, 1000); 2586 2660 if (!pool) { 2587 PJSUA_UNLOCK();2588 return PJ_ENOMEM;2661 status = PJ_ENOMEM; 2662 goto on_error; 2589 2663 } 2590 2664 … … 2596 2670 options, 0, &port); 2597 2671 if (status != PJ_SUCCESS) { 2598 PJSUA_UNLOCK();2599 2672 pjsua_perror(THIS_FILE, "Unable to open file for playback", status); 2600 pj_pool_release(pool); 2601 return status; 2673 goto on_error; 2602 2674 } 2603 2675 … … 2606 2678 if (status != PJ_SUCCESS) { 2607 2679 pjmedia_port_destroy(port); 2608 PJSUA_UNLOCK();2609 2680 pjsua_perror(THIS_FILE, "Unable to add file to conference bridge", 2610 2681 status); 2611 pj_pool_release(pool); 2612 return status; 2682 goto on_error; 2613 2683 } 2614 2684 … … 2623 2693 2624 2694 PJSUA_UNLOCK(); 2695 2696 PJ_LOG(4,(THIS_FILE, "Player created, id=%d, slot=%d", file_id, slot)); 2697 2698 pj_log_pop_indent(); 2625 2699 return PJ_SUCCESS; 2700 2701 on_error: 2702 PJSUA_UNLOCK(); 2703 if (pool) pj_pool_release(pool); 2704 pj_log_pop_indent(); 2705 return status; 2626 2706 } 2627 2707 … … 2638 2718 { 2639 2719 unsigned slot, file_id, ptime; 2640 pj_pool_t *pool ;2720 pj_pool_t *pool = NULL; 2641 2721 pjmedia_port *port; 2642 pj_status_t status ;2722 pj_status_t status = PJ_SUCCESS; 2643 2723 2644 2724 if (pjsua_var.player_cnt >= PJ_ARRAY_SIZE(pjsua_var.player)) 2645 2725 return PJ_ETOOMANY; 2726 2727 PJ_LOG(4,(THIS_FILE, "Creating playlist with %d file(s)..", file_count)); 2728 pj_log_push_indent(); 2646 2729 2647 2730 PJSUA_LOCK(); … … 2654 2737 if (file_id == PJ_ARRAY_SIZE(pjsua_var.player)) { 2655 2738 /* This is unexpected */ 2656 PJSUA_UNLOCK();2657 2739 pj_assert(0); 2658 return PJ_EBUG; 2740 status = PJ_EBUG; 2741 goto on_error; 2659 2742 } 2660 2743 … … 2665 2748 pool = pjsua_pool_create("playlist", 1000, 1000); 2666 2749 if (!pool) { 2667 PJSUA_UNLOCK();2668 return PJ_ENOMEM;2750 status = PJ_ENOMEM; 2751 goto on_error; 2669 2752 } 2670 2753 … … 2673 2756 ptime, options, 0, &port); 2674 2757 if (status != PJ_SUCCESS) { 2675 PJSUA_UNLOCK();2676 2758 pjsua_perror(THIS_FILE, "Unable to create playlist", status); 2677 pj_pool_release(pool); 2678 return status; 2759 goto on_error; 2679 2760 } 2680 2761 … … 2683 2764 if (status != PJ_SUCCESS) { 2684 2765 pjmedia_port_destroy(port); 2685 PJSUA_UNLOCK();2686 2766 pjsua_perror(THIS_FILE, "Unable to add port", status); 2687 pj_pool_release(pool); 2688 return status; 2767 goto on_error; 2689 2768 } 2690 2769 … … 2699 2778 2700 2779 PJSUA_UNLOCK(); 2780 2781 PJ_LOG(4,(THIS_FILE, "Playlist created, id=%d, slot=%d", file_id, slot)); 2782 2783 pj_log_pop_indent(); 2784 2701 2785 return PJ_SUCCESS; 2702 2786 2787 on_error: 2788 PJSUA_UNLOCK(); 2789 if (pool) pj_pool_release(pool); 2790 pj_log_pop_indent(); 2791 2792 return status; 2703 2793 } 2704 2794 … … 2752 2842 PJ_ASSERT_RETURN(id>=0&&id<(int)PJ_ARRAY_SIZE(pjsua_var.player), PJ_EINVAL); 2753 2843 PJ_ASSERT_RETURN(pjsua_var.player[id].port != NULL, PJ_EINVAL); 2844 2845 PJ_LOG(4,(THIS_FILE, "Destroying player %d..", id)); 2846 pj_log_push_indent(); 2754 2847 2755 2848 PJSUA_LOCK(); … … 2766 2859 2767 2860 PJSUA_UNLOCK(); 2861 pj_log_pop_indent(); 2768 2862 2769 2863 return PJ_SUCCESS; … … 2796 2890 pj_str_t ext; 2797 2891 int file_format; 2798 pj_pool_t *pool ;2892 pj_pool_t *pool = NULL; 2799 2893 pjmedia_port *port; 2800 pj_status_t status ;2894 pj_status_t status = PJ_SUCCESS; 2801 2895 2802 2896 /* Filename must present */ … … 2809 2903 PJ_ASSERT_RETURN(enc_type == 0, PJ_EINVAL); 2810 2904 2811 if (pjsua_var.rec_cnt >= PJ_ARRAY_SIZE(pjsua_var.recorder)) 2905 PJ_LOG(4,(THIS_FILE, "Creating recorder %.*s..", 2906 (int)filename->slen, filename->ptr)); 2907 pj_log_push_indent(); 2908 2909 if (pjsua_var.rec_cnt >= PJ_ARRAY_SIZE(pjsua_var.recorder)) { 2910 pj_log_pop_indent(); 2812 2911 return PJ_ETOOMANY; 2912 } 2813 2913 2814 2914 /* Determine the file format */ … … 2824 2924 "determine file format for %.*s", 2825 2925 (int)filename->slen, filename->ptr)); 2926 pj_log_pop_indent(); 2826 2927 return PJ_ENOTSUP; 2827 2928 } … … 2836 2937 if (file_id == PJ_ARRAY_SIZE(pjsua_var.recorder)) { 2837 2938 /* This is unexpected */ 2838 PJSUA_UNLOCK();2839 2939 pj_assert(0); 2840 return PJ_EBUG; 2940 status = PJ_EBUG; 2941 goto on_return; 2841 2942 } 2842 2943 … … 2846 2947 pool = pjsua_pool_create(get_basename(path, filename->slen), 1000, 1000); 2847 2948 if (!pool) { 2848 PJSUA_UNLOCK();2849 return PJ_ENOMEM;2949 status = PJ_ENOMEM; 2950 goto on_return; 2850 2951 } 2851 2952 … … 2864 2965 2865 2966 if (status != PJ_SUCCESS) { 2866 PJSUA_UNLOCK();2867 2967 pjsua_perror(THIS_FILE, "Unable to open file for recording", status); 2868 pj_pool_release(pool); 2869 return status; 2968 goto on_return; 2870 2969 } 2871 2970 … … 2874 2973 if (status != PJ_SUCCESS) { 2875 2974 pjmedia_port_destroy(port); 2876 PJSUA_UNLOCK(); 2877 pj_pool_release(pool); 2878 return status; 2975 goto on_return; 2879 2976 } 2880 2977 … … 2888 2985 2889 2986 PJSUA_UNLOCK(); 2987 2988 PJ_LOG(4,(THIS_FILE, "Recorder created, id=%d, slot=%d", file_id, slot)); 2989 2990 pj_log_pop_indent(); 2890 2991 return PJ_SUCCESS; 2992 2993 on_return: 2994 PJSUA_UNLOCK(); 2995 if (pool) pj_pool_release(pool); 2996 pj_log_pop_indent(); 2997 return status; 2891 2998 } 2892 2999 … … 2927 3034 PJ_EINVAL); 2928 3035 PJ_ASSERT_RETURN(pjsua_var.recorder[id].port != NULL, PJ_EINVAL); 3036 3037 PJ_LOG(4,(THIS_FILE, "Destroying recorder %d..", id)); 3038 pj_log_push_indent(); 2929 3039 2930 3040 PJSUA_LOCK(); … … 2941 3051 2942 3052 PJSUA_UNLOCK(); 3053 pj_log_pop_indent(); 2943 3054 2944 3055 return PJ_SUCCESS; … … 3148 3259 param->base.samples_per_frame / param->base.channel_count * 3149 3260 1000 / param->base.clock_rate)); 3261 pj_log_push_indent(); 3150 3262 3151 3263 status = pjmedia_snd_port_create2( pjsua_var.snd_pool, 3152 3264 param, &pjsua_var.snd_port); 3153 3265 if (status != PJ_SUCCESS) 3154 return status;3266 goto on_error; 3155 3267 3156 3268 /* Get the port0 of the conference bridge. */ … … 3189 3301 errmsg)); 3190 3302 close_snd_dev(); 3191 return status;3303 goto on_error; 3192 3304 } 3193 3305 … … 3218 3330 pjmedia_snd_port_destroy(pjsua_var.snd_port); 3219 3331 pjsua_var.snd_port = NULL; 3220 return status;3332 goto on_error; 3221 3333 } 3222 3334 … … 3256 3368 /* Any error is not major, let it through */ 3257 3369 status = PJ_SUCCESS; 3258 } ;3370 } 3259 3371 3260 3372 /* If this is the first time the audio device is open, retrieve some … … 3267 3379 } 3268 3380 3381 pj_log_pop_indent(); 3269 3382 return PJ_SUCCESS; 3383 3384 on_error: 3385 pj_log_pop_indent(); 3386 return status; 3270 3387 } 3271 3388 … … 3274 3391 static void close_snd_dev(void) 3275 3392 { 3393 pj_log_push_indent(); 3394 3276 3395 /* Notify app */ 3277 3396 if (pjsua_var.snd_is_on && pjsua_var.ua_cfg.cb.on_snd_dev_operation) { … … 3313 3432 pjsua_var.snd_pool = NULL; 3314 3433 pjsua_var.snd_is_on = PJ_FALSE; 3434 3435 pj_log_pop_indent(); 3315 3436 } 3316 3437 … … 3328 3449 pj_status_t status = -1; 3329 3450 3451 PJ_LOG(4,(THIS_FILE, "Set sound device: capture=%d, playback=%d", 3452 capture_dev, playback_dev)); 3453 pj_log_push_indent(); 3454 3330 3455 /* Null-sound */ 3331 3456 if (capture_dev==NULL_SND_DEV_ID && playback_dev==NULL_SND_DEV_ID) { 3332 return pjsua_set_null_snd_dev(); 3457 status = pjsua_set_null_snd_dev(); 3458 pj_log_pop_indent(); 3459 return status; 3333 3460 } 3334 3461 … … 3361 3488 samples_per_frame, 16); 3362 3489 if (status != PJ_SUCCESS) 3363 return status;3490 goto on_error; 3364 3491 3365 3492 /* Open! */ … … 3372 3499 if (status != PJ_SUCCESS) { 3373 3500 pjsua_perror(THIS_FILE, "Unable to open sound device", status); 3374 return status;3501 goto on_error; 3375 3502 } 3376 3503 … … 3378 3505 pjsua_var.snd_is_on = PJ_TRUE; 3379 3506 3507 pj_log_pop_indent(); 3380 3508 return PJ_SUCCESS; 3509 3510 on_error: 3511 pj_log_pop_indent(); 3512 return status; 3381 3513 } 3382 3514 … … 3408 3540 pjmedia_port *conf_port; 3409 3541 pj_status_t status; 3542 3543 PJ_LOG(4,(THIS_FILE, "Setting null sound device..")); 3544 pj_log_push_indent(); 3545 3410 3546 3411 3547 /* Close existing sound device */ … … 3435 3571 pjsua_perror(THIS_FILE, "Unable to create null sound device", 3436 3572 status); 3573 pj_log_pop_indent(); 3437 3574 return status; 3438 3575 } … … 3448 3585 pjsua_var.snd_is_on = PJ_TRUE; 3449 3586 3587 pj_log_pop_indent(); 3450 3588 return PJ_SUCCESS; 3451 3589 }
Note: See TracChangeset
for help on using the changeset viewer.