[Freeswitch-svn] [commit] r10299 - freeswitch/trunk/src/mod/applications/mod_fifo

FreeSWITCH SVN mikej at freeswitch.org
Fri Nov 7 15:46:27 PST 2008


Author: mikej
Date: Fri Nov  7 18:46:27 2008
New Revision: 10299

Modified:
   freeswitch/trunk/src/mod/applications/mod_fifo/mod_fifo.c

Log:
fix fifo build

Modified: freeswitch/trunk/src/mod/applications/mod_fifo/mod_fifo.c
==============================================================================
--- freeswitch/trunk/src/mod/applications/mod_fifo/mod_fifo.c	(original)
+++ freeswitch/trunk/src/mod/applications/mod_fifo/mod_fifo.c	Fri Nov  7 18:46:27 2008
@@ -29,6 +29,9 @@
  *
  */
 #include <switch.h>
+#ifdef SWITCH_HAVE_ODBC
+#include <switch_odbc.h>
+#endif
 
 SWITCH_MODULE_SHUTDOWN_FUNCTION(mod_fifo_shutdown);
 SWITCH_MODULE_LOAD_FUNCTION(mod_fifo_load);
@@ -1745,8 +1748,6 @@
 				const char *simo = switch_xml_attr_soft(member, "simo");
 				const char *lag = switch_xml_attr_soft(member, "lag");
 				const char *timeout = switch_xml_attr_soft(member, "timeout");
-				
-				char *sql;
 				char digest[SWITCH_MD5_DIGEST_STRING_SIZE] = { 0 };
 				switch_md5_string(digest, (void *) member->txt, strlen(member->txt));
 
@@ -1866,7 +1867,7 @@
 	fifo_name = argv[1];
 	originate_string = argv[2];
 	
-	if (!strcasecmp(action, "add")) {
+	if (action && !strcasecmp(action, "add")) {
 		if (argc > 3) {
 			simo_count = atoi(argv[3]);
 		}
@@ -1891,7 +1892,7 @@
 		
 		fifo_member_add(fifo_name, originate_string, simo_count, timeout, lag, expires);
 		stream->write_function(stream, "%s", "+OK\n");
-	} else if (!strcasecmp(action, "del")) {
+	} else if (action && !strcasecmp(action, "del")) {
 		fifo_member_del(fifo_name, originate_string);
 		stream->write_function(stream, "%s", "+OK\n");
 	} else {



More information about the Freeswitch-svn mailing list