[Asterisk-cvs] asterisk/channels chan_features.c,1.3,1.4

markster at lists.digium.com markster at lists.digium.com
Thu Dec 23 17:33:47 CST 2004


Update of /usr/cvsroot/asterisk/channels
In directory mongoose.digium.com:/tmp/cvs-serv1987/channels

Modified Files:
	chan_features.c 
Log Message:
Small fix for features channel driver


Index: chan_features.c
===================================================================
RCS file: /usr/cvsroot/asterisk/channels/chan_features.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- chan_features.c	23 Dec 2004 11:35:21 -0000	1.3
+++ chan_features.c	23 Dec 2004 22:29:23 -0000	1.4
@@ -381,7 +381,7 @@
 		ast_log(LOG_WARNING, "Called upon channel with no subchan:(\n");
 		return NULL;
 	}
-	if (!p->subs[index].owner) {
+	if (p->subs[index].owner) {
 		ast_log(LOG_WARNING, "Called to put index %d already there!\n", index);
 		return NULL;
 	}
@@ -415,6 +415,8 @@
 		tmp->pvt->indicate = features_indicate;
 		tmp->pvt->fixup = features_fixup;
 		p->subs[index].owner = tmp;
+		if (!p->owner)
+			p->owner = tmp;
 		ast_mutex_lock(&usecnt_lock);
 		usecnt++;
 		ast_mutex_unlock(&usecnt_lock);




More information about the svn-commits mailing list