From 5964e318732b75bcadd716deca0d22b6a5793787 Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Wed, 4 Nov 2009 22:55:33 +0000 Subject: [PATCH] missed a spot git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@15359 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/switch_channel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/switch_channel.c b/src/switch_channel.c index a80c6f5cfc..eb89cf9831 100644 --- a/src/switch_channel.c +++ b/src/switch_channel.c @@ -1748,7 +1748,7 @@ SWITCH_DECLARE(void) switch_channel_clear_state_handler(switch_channel_t *channe channel->state_handlers[index] = NULL; } - if (state_handler) { + if (channel->state_handler_index > 0) { for (index = 0; index < channel->state_handler_index; index++) { channel->state_handlers[index] = new_handlers[index]; }