[asterisk-commits] dlee: branch dlee/ASTERISK-21096 r383614 - /team/dlee/ASTERISK-21096/main/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Mar 22 15:13:11 CDT 2013


Author: dlee
Date: Fri Mar 22 15:13:08 2013
New Revision: 383614

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=383614
Log:
Bit more cleanup, as suggested by opticron

Modified:
    team/dlee/ASTERISK-21096/main/manager_channels.c

Modified: team/dlee/ASTERISK-21096/main/manager_channels.c
URL: http://svnview.digium.com/svn/asterisk/team/dlee/ASTERISK-21096/main/manager_channels.c?view=diff&rev=383614&r1=383613&r2=383614
==============================================================================
--- team/dlee/ASTERISK-21096/main/manager_channels.c (original)
+++ team/dlee/ASTERISK-21096/main/manager_channels.c Fri Mar 22 15:13:08 2013
@@ -298,8 +298,6 @@
 		return NULL;
 	}
 
-	was_hungup = (old_snapshot && ast_test_flag(&old_snapshot->flags, AST_FLAG_ZOMBIE)) ? 1 : 0;
-	is_hungup = ast_test_flag(&new_snapshot->flags, AST_FLAG_ZOMBIE) ? 1 : 0;
 
 	/* The Newchannel, Newstate and Hangup events are closely related, in
 	 * in that they are mutually exclusive, basically different flavors
@@ -310,6 +308,10 @@
 		return snapshot_manager_event_create(
 			EVENT_FLAG_CALL, "Newchannel", NO_EXTRA_FIELDS);
 	}
+
+
+	was_hungup = ast_test_flag(&old_snapshot->flags, AST_FLAG_ZOMBIE) ? 1 : 0;
+	is_hungup = ast_test_flag(&new_snapshot->flags, AST_FLAG_ZOMBIE) ? 1 : 0;
 
 	if (!was_hungup && is_hungup) {
 		return snapshot_manager_event_create(




More information about the asterisk-commits mailing list