mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-08-14 09:58:17 +00:00
add session.getState()
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@14924 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
@@ -938,6 +938,18 @@ SWITCH_DECLARE(const char *) CoreSession::hangupCause()
|
||||
return switch_channel_cause2str(cause);
|
||||
}
|
||||
|
||||
SWITCH_DECLARE(const char *) CoreSession::getState()
|
||||
{
|
||||
this_check(NULL);
|
||||
|
||||
if (channel) {
|
||||
return switch_channel_state_name(switch_channel_get_state(channel));
|
||||
}
|
||||
|
||||
return "ERROR";
|
||||
|
||||
}
|
||||
|
||||
SWITCH_DECLARE(int) CoreSession::originate(CoreSession *a_leg_session, char *dest, int timeout, switch_state_handler_table_t *handlers)
|
||||
{
|
||||
|
||||
|
Reference in New Issue
Block a user