FS-2966 I already fixed this in the wait_for_state, so i copied the same fix to wait_for_state_timeout, the lua one needed a similar call to wait for the state to change to avoid a race, both of you should be fixed with this patch

This commit is contained in:
Anthony Minessale
2011-03-02 20:50:33 -06:00
parent 08496cd7eb
commit f33e9c6ede
2 changed files with 6 additions and 3 deletions

View File

@@ -516,6 +516,7 @@ SWITCH_DECLARE_CONSTRUCTOR CoreSession::CoreSession(char *nuuid, CoreSession *a_
switch_set_flag(this, S_HUP);
uuid = strdup(switch_core_session_get_uuid(session));
switch_channel_set_state(switch_core_session_get_channel(session), CS_SOFT_EXECUTE);
switch_channel_wait_for_state(switch_core_session_get_channel(session), switch_core_session_get_channel(a_leg->session), CS_SOFT_EXECUTE);
}
}
}