]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
move set
authorAnthony Minessale <anthony.minessale@gmail.com>
Wed, 31 Oct 2007 23:19:30 +0000 (23:19 +0000)
committerAnthony Minessale <anthony.minessale@gmail.com>
Wed, 31 Oct 2007 23:19:30 +0000 (23:19 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@6116 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/switch_ivr.c

index 636830ece515f928999bbc59bb6940503379bcd4..7c91866c35ab0cc43a6e49e933387caef05dc09e 100644 (file)
@@ -417,12 +417,12 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_park(switch_core_session_t *session,
                switch_channel_pre_answer(channel);
        }
 
+       switch_channel_set_flag(channel, CF_CONTROLLED);
        if (switch_event_create(&event, SWITCH_EVENT_CHANNEL_PARK) == SWITCH_STATUS_SUCCESS) {
                switch_channel_event_set_data(channel, event);
                switch_event_fire(&event);
        }
 
-       switch_channel_set_flag(channel, CF_CONTROLLED);
        while (switch_channel_ready(channel) && switch_channel_test_flag(channel, CF_CONTROLLED)) {
 
                if ((status = switch_core_session_read_frame(session, &read_frame, -1, stream_id)) == SWITCH_STATUS_SUCCESS) {