From a4a89487749060b43b484ce47dfffbf23dcd2c4f Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Wed, 23 Oct 2013 23:09:14 -0500 Subject: [PATCH] tweak to devstate --- src/switch_channel.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/switch_channel.c b/src/switch_channel.c index 24c8e03489..a2c87414dd 100644 --- a/src/switch_channel.c +++ b/src/switch_channel.c @@ -4708,6 +4708,13 @@ static void fetch_device_stats(switch_device_record_t *drec) } else { drec->stats.ringing_out++; } + } else if (np->callstate == CCS_HANGUP) { + drec->stats.hup++; + if (np->direction == SWITCH_CALL_DIRECTION_INBOUND) { + drec->stats.hup_in++; + } else { + drec->stats.hup_out++; + } } else if (np->callstate != CCS_DOWN) { drec->stats.active++; if (np->direction == SWITCH_CALL_DIRECTION_INBOUND) {