[asterisk-commits] kmoore: branch kmoore/stasis_http_rename r395545 - /team/kmoore/stasis_http_r...
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Fri Jul 26 13:31:49 CDT 2013
Author: kmoore
Date: Fri Jul 26 13:31:47 2013
New Revision: 395545
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=395545
Log:
Fix merge conflict
Modified:
team/kmoore/stasis_http_rename/res/ari/resource_events.c
Modified: team/kmoore/stasis_http_rename/res/ari/resource_events.c
URL: http://svnview.digium.com/svn/asterisk/team/kmoore/stasis_http_rename/res/ari/resource_events.c?view=diff&rev=395545&r1=395544&r2=395545
==============================================================================
--- team/kmoore/stasis_http_rename/res/ari/resource_events.c (original)
+++ team/kmoore/stasis_http_rename/res/ari/resource_events.c Fri Jul 26 13:31:47 2013
@@ -113,6 +113,19 @@
{
struct event_session *session = data;
int res;
+ const char *msg_type = S_OR(
+ ast_json_string_get(ast_json_object_get(message, "type")),
+ "");
+ const char *msg_application = S_OR(
+ ast_json_string_get(ast_json_object_get(message, "application")),
+ "");
+
+ /* Determine if we've been replaced */
+ if (strcmp(msg_type, "ApplicationReplaced") == 0 &&
+ strcmp(msg_application, app_name) == 0) {
+ ao2_find(session->websocket_apps, msg_application,
+ OBJ_UNLINK | OBJ_NODATA);
+ }
res = ast_json_object_set(message, "application",
ast_json_string_create(app_name));
More information about the asterisk-commits
mailing list