From 002896a4a2f468ce85166a0948139533c5d768bb Mon Sep 17 00:00:00 2001 From: Michael Jerris Date: Mon, 26 Apr 2010 05:18:46 -0400 Subject: [PATCH] add 'direction' chan var --- src/switch_channel.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/switch_channel.c b/src/switch_channel.c index acefec30dc..e08bc4f63a 100644 --- a/src/switch_channel.c +++ b/src/switch_channel.c @@ -241,6 +241,7 @@ SWITCH_DECLARE(switch_status_t) switch_channel_alloc(switch_channel_t **channel, (*channel)->hangup_cause = SWITCH_CAUSE_NONE; (*channel)->name = ""; (*channel)->direction = direction; + switch_channel_set_variable(*channel, "direction", switch_channel_direction(*channel) == SWITCH_CALL_DIRECTION_OUTBOUND ? "outbound" : "inbound"); return SWITCH_STATUS_SUCCESS; }