[asterisk-commits] eliel: trunk r275509 - /trunk/apps/app_meetme.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Sat Jul 10 15:49:35 CDT 2010


Author: eliel
Date: Sat Jul 10 15:49:30 2010
New Revision: 275509

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=275509
Log:
When creating a conference for a unit test, it is not mandatory to open a
dahdi pseudo channel, so if we fail doing it, continue creating the conference.


Modified:
    trunk/apps/app_meetme.c

Modified: trunk/apps/app_meetme.c
URL: http://svnview.digium.com/svn/asterisk/trunk/apps/app_meetme.c?view=diff&rev=275509&r1=275508&r2=275509
==============================================================================
--- trunk/apps/app_meetme.c (original)
+++ trunk/apps/app_meetme.c Sat Jul 10 15:49:30 2010
@@ -1186,14 +1186,18 @@
 	cnf->fd = open("/dev/dahdi/pseudo", O_RDWR);
 	if (cnf->fd < 0 || ioctl(cnf->fd, DAHDI_SETCONF, &dahdic)) {
 		if (test) {
+			/* if we are creating a conference for a unit test, it is not neccesary
+			 * to open a pseudo channel, so, if we fail continue creating
+			 * the conference. */
 			ast_test_status_update(test, "Unable to open pseudo device\n");
-		}
-		ast_log(LOG_WARNING, "Unable to open pseudo device\n");
-		if (cnf->fd >= 0)
-			close(cnf->fd);
-		ast_free(cnf);
-		cnf = NULL;
-		goto cnfout;
+		} else {
+			ast_log(LOG_WARNING, "Unable to open pseudo device\n");
+			if (cnf->fd >= 0)
+				close(cnf->fd);
+			ast_free(cnf);
+			cnf = NULL;
+			goto cnfout;
+		}
 	}
 
 	cnf->dahdiconf = dahdic.confno;




More information about the asterisk-commits mailing list