[asterisk-commits] dlee: branch dlee/stasis-vtable r390150 - in /team/dlee/stasis-vtable: includ...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu May 30 14:06:27 CDT 2013


Author: dlee
Date: Thu May 30 14:06:25 2013
New Revision: 390150

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=390150
Log:
Cleanup

Modified:
    team/dlee/stasis-vtable/include/asterisk/stasis.h
    team/dlee/stasis-vtable/include/asterisk/stasis_channels.h
    team/dlee/stasis-vtable/main/parking.c
    team/dlee/stasis-vtable/tests/test_stasis.c

Modified: team/dlee/stasis-vtable/include/asterisk/stasis.h
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-vtable/include/asterisk/stasis.h?view=diff&rev=390150&r1=390149&r2=390150
==============================================================================
--- team/dlee/stasis-vtable/include/asterisk/stasis.h (original)
+++ team/dlee/stasis-vtable/include/asterisk/stasis.h Thu May 30 14:06:25 2013
@@ -735,7 +735,7 @@
 		ast_assert(_priv_ ## name == NULL);			\
 		_priv_ ## name = stasis_message_type_create(#name,	\
 			&_priv_ ## name ## _v);				\
-			_priv_ ## name ? 0 : -1;			\
+		_priv_ ## name ? 0 : -1;				\
 	})
 
 /*!

Modified: team/dlee/stasis-vtable/include/asterisk/stasis_channels.h
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-vtable/include/asterisk/stasis_channels.h?view=diff&rev=390150&r1=390149&r2=390150
==============================================================================
--- team/dlee/stasis-vtable/include/asterisk/stasis_channels.h (original)
+++ team/dlee/stasis-vtable/include/asterisk/stasis_channels.h Thu May 30 14:06:25 2013
@@ -170,8 +170,6 @@
 	const char *uniqueid, struct stasis_message_type *type,
 	struct ast_json *blob);
 
-struct ast_json *ast_channel_blob_to_json(struct stasis_message *msg);
-
 /*!
  * \since 12
  * \brief Create a \ref ast_multi_channel_blob suitable for a \ref stasis_message.

Modified: team/dlee/stasis-vtable/main/parking.c
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-vtable/main/parking.c?view=diff&rev=390150&r1=390149&r2=390150
==============================================================================
--- team/dlee/stasis-vtable/main/parking.c (original)
+++ team/dlee/stasis-vtable/main/parking.c Thu May 30 14:06:25 2013
@@ -35,7 +35,7 @@
 #include "asterisk/channel.h"
 
 /*! \brief Message type for parked calls */
-static struct stasis_message_type *parked_call_type;
+STASIS_MESSAGE_TYPE_DEFN(ast_parked_call_type);
 
 /*! \brief Topic for parking lots */
 static struct stasis_topic *parking_topic;
@@ -48,26 +48,20 @@
 
 void ast_parking_stasis_init(void)
 {
-	parked_call_type = stasis_message_type_create("ast_parked_call", NULL);
+	STASIS_MESSAGE_TYPE_INIT(ast_parked_call_type);
 	parking_topic = stasis_topic_create("ast_parking");
 }
 
 void ast_parking_stasis_disable(void)
 {
-	ao2_cleanup(parked_call_type);
+	STASIS_MESSAGE_TYPE_CLEANUP(ast_parked_call_type);
 	ao2_cleanup(parking_topic);
-	parked_call_type = NULL;
 	parking_topic = NULL;
 }
 
 struct stasis_topic *ast_parking_topic(void)
 {
 	return parking_topic;
-}
-
-struct stasis_message_type *ast_parked_call_type(void)
-{
-	return parked_call_type;
 }
 
 /*! \brief Destructor for parked_call_payload objects */

Modified: team/dlee/stasis-vtable/tests/test_stasis.c
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-vtable/tests/test_stasis.c?view=diff&rev=390150&r1=390149&r2=390150
==============================================================================
--- team/dlee/stasis-vtable/tests/test_stasis.c (original)
+++ team/dlee/stasis-vtable/tests/test_stasis.c Thu May 30 14:06:25 2013
@@ -1066,8 +1066,6 @@
 
 	expected = ast_json_string_create(expected_text);
 	actual = stasis_message_to_json(uut);
-	printf("Expected: %s\n", ast_json_string_get(expected));
-	printf("Actual: %s\n", ast_json_string_get(actual));
 	ast_test_validate(test, ast_json_equal(expected, actual));
 
 	return AST_TEST_PASS;




More information about the asterisk-commits mailing list