From a2a53cc306ea5fec65daf3630716a7c6ee13adad Mon Sep 17 00:00:00 2001 From: "David M. Lee" Date: Mon, 8 Apr 2013 13:27:45 +0000 Subject: Stasis application WebSocket support This is the API that binds the Stasis dialplan application to external Stasis applications. It also adds the beginnings of WebSocket application support. This module registers a dialplan function named Stasis, which is used to put a channel into the named Stasis app. As a channel enters and leaves the Stasis diaplan application, the Stasis app receives a 'stasis-start' and 'stasis-end' events. Stasis apps register themselves using the stasis_app_register and stasis_app_unregister functions. Messages are sent to an application using stasis_app_send. Finally, Stasis apps control channels through the use of the stasis_app_control object, and the family of stasis_app_control_* functions. Other changes along for the ride are: * An ast_frame_dtor function that's RAII_VAR safe * Some common JSON encoders for name/number, timeval, and context/extension/priority Review: https://reviewboard.asterisk.org/r/2361/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@384879 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- main/frame.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'main/frame.c') diff --git a/main/frame.c b/main/frame.c index a3f67da61..b559d552d 100644 --- a/main/frame.c +++ b/main/frame.c @@ -351,6 +351,13 @@ void ast_frame_free(struct ast_frame *frame, int cache) } } +void ast_frame_dtor(struct ast_frame *f) +{ + if (f) { + ast_frfree(f); + } +} + /*! * \brief 'isolates' a frame by duplicating non-malloc'ed components * (header, src, data). -- cgit v1.2.3