[asterisk-commits] russell: branch russell/events r84547 - in /team/russell/events: include/aste...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Oct 3 13:47:14 CDT 2007


Author: russell
Date: Wed Oct  3 13:47:13 2007
New Revision: 84547

URL: http://svn.digium.com/view/asterisk?view=rev&rev=84547
Log:
return NULL from ast_event_unsubscribe for convenience

Modified:
    team/russell/events/include/asterisk/event.h
    team/russell/events/main/event.c

Modified: team/russell/events/include/asterisk/event.h
URL: http://svn.digium.com/view/asterisk/team/russell/events/include/asterisk/event.h?view=diff&rev=84547&r1=84546&r2=84547
==============================================================================
--- team/russell/events/include/asterisk/event.h (original)
+++ team/russell/events/include/asterisk/event.h Wed Oct  3 13:47:13 2007
@@ -128,10 +128,13 @@
  *
  * \param event_sub This is the reference to the subscription returned by
  *        ast_event_subscribe.
- * 
- * \return Nothing
- */
-void ast_event_unsubscribe(struct ast_event_sub *event_sub);
+ *
+ * This function will remove a subscription and free the associated data
+ * structures.
+ *
+ * \return NULL for convenience.
+ */
+struct ast_event_sub *ast_event_unsubscribe(struct ast_event_sub *event_sub);
 
 /*!
  * \brief Check if subscribers exist

Modified: team/russell/events/main/event.c
URL: http://svn.digium.com/view/asterisk/team/russell/events/main/event.c?view=diff&rev=84547&r1=84546&r2=84547
==============================================================================
--- team/russell/events/main/event.c (original)
+++ team/russell/events/main/event.c Wed Oct  3 13:47:13 2007
@@ -25,7 +25,7 @@
 
 #include "asterisk.h"
 
-ASTERISK_FILE_VERSION(__FILE__, "$Revision: 79039 $")
+ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 
 #include <stdlib.h>
 #include <stdio.h>
@@ -469,7 +469,7 @@
 	ast_free(sub);
 }
 
-void ast_event_unsubscribe(struct ast_event_sub *sub)
+struct ast_event_sub *ast_event_unsubscribe(struct ast_event_sub *sub)
 {
 	struct ast_event *event;
 
@@ -491,6 +491,8 @@
 	}
 
 	ast_event_sub_destroy(sub);
+
+	return NULL;
 }
 
 void ast_event_iterator_init(struct ast_event_iterator *iterator, const struct ast_event *event)




More information about the asterisk-commits mailing list