PJ_DEF(pj_status_t) pjsua_start(void)
{
    pj_status_t status;

    pjsua_set_state(PJSUA_STATE_STARTING);
    pj_log_push_indent();

    status = pjsua_call_subsys_start();
    if (status != PJ_SUCCESS)
	goto on_return;

    status = pjsua_media_subsys_start();
    if (status != PJ_SUCCESS)
	goto on_return;

    status = pjsua_pres_start();
    if (status != PJ_SUCCESS)
	goto on_return;

    pjsua_set_state(PJSUA_STATE_RUNNING);

on_return:
    pj_log_pop_indent();
    return status;
}
PJ_DEF(pj_status_t) pjsua_start(void)
{
    pj_status_t status;

    pjsua_set_state(PJSUA_STATE_STARTING);
    pj_log_push_indent();

    status = pjsua_call_subsys_start();
    if (status != PJ_SUCCESS)
	goto on_return;

    status = pjsua_media_subsys_start();
    if (status != PJ_SUCCESS)
	goto on_return;

    status = pjsua_pres_start();
    if (status != PJ_SUCCESS)
	goto on_return;

    pjsua_set_state(PJSUA_STATE_RUNNING);

on_return:
    pj_log_pop_indent();
    return status;
}