[asterisk-commits] file: trunk r48378 - in /trunk: ./ apps/app_meetme.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Sun Dec 10 22:01:37 MST 2006


Author: file
Date: Sun Dec 10 23:01:37 2006
New Revision: 48378

URL: http://svn.digium.com/view/asterisk?view=rev&rev=48378
Log:
Merged revisions 48377 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r48377 | file | 2006-12-10 23:57:38 -0500 (Sun, 10 Dec 2006) | 2 lines

Don't access the conference structure after it has been freed.

........

Modified:
    trunk/   (props changed)
    trunk/apps/app_meetme.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/apps/app_meetme.c
URL: http://svn.digium.com/view/asterisk/trunk/apps/app_meetme.c?view=diff&rev=48378&r1=48377&r2=48378
==============================================================================
--- trunk/apps/app_meetme.c (original)
+++ trunk/apps/app_meetme.c Sun Dec 10 23:01:37 2006
@@ -1945,6 +1945,13 @@
 			conf->markedusers--;
 		/* Remove ourselves from the list */
 		AST_LIST_REMOVE(&conf->userlist, user, list);
+
+		/* Change any states */
+		if (!conf->users)
+			ast_device_state_changed("meetme:%s", conf->confno);
+		if (confflags & (CONFFLAG_SLA_STATION|CONFFLAG_SLA_TRUNK))
+			st_device_state_changed("SLA:%s", conf->confno + 4);
+
 		if (AST_LIST_EMPTY(&conf->userlist)) {
 			/* close this one when no more users and no references*/
 			if (!conf->refcount)
@@ -1953,12 +1960,6 @@
 		/* Return the number of seconds the user was in the conf */
 		snprintf(meetmesecs, sizeof(meetmesecs), "%d", (int) (time(NULL) - user->jointime));
 		pbx_builtin_setvar_helper(chan, "MEETMESECS", meetmesecs);
-
-		/* This device changed state now */
-		if (!conf->users)	/* If there are no more members */
-			ast_device_state_changed("meetme:%s", conf->confno);
-		if (confflags & (CONFFLAG_SLA_STATION|CONFFLAG_SLA_TRUNK))
-			ast_device_state_changed("SLA:%s", conf->confno + 4);
 	}
 	free(user);
 	AST_LIST_UNLOCK(&confs);



More information about the asterisk-commits mailing list