[Freeswitch-svn] [commit] r7382 - in freeswitch/trunk/src/mod/xml_int: mod_xml_cdr mod_xml_curl mod_xml_rpc

Freeswitch SVN brian at freeswitch.org
Sat Jan 26 22:03:09 EST 2008


Author: brian
Date: Sat Jan 26 22:03:09 2008
New Revision: 7382

Modified:
   freeswitch/trunk/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c
   freeswitch/trunk/src/mod/xml_int/mod_xml_curl/mod_xml_curl.c
   freeswitch/trunk/src/mod/xml_int/mod_xml_rpc/mod_xml_rpc.c

Log:
whitespace cleanup...

Modified: freeswitch/trunk/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c
==============================================================================
--- freeswitch/trunk/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c	(original)
+++ freeswitch/trunk/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c	Sat Jan 26 22:03:09 2008
@@ -179,7 +179,6 @@
 			} else {
 				switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Got error [%ld] posting to web server [%s]\n",httpRes, globals.url);
 			}
-			
 		}
 		curl_easy_cleanup(curl_handle);
 		curl_slist_free_all(headers);
@@ -209,7 +208,6 @@
 		}
 	}
 
-
 success:
 	status = SWITCH_STATUS_SUCCESS;
 
@@ -225,7 +223,6 @@
 	return status;
 }
 
-
 static switch_state_handler_table_t state_handlers = {
 	/*.on_init */ NULL,
 	/*.on_ring */ NULL,
@@ -326,7 +323,6 @@
 		globals.retries = 0;
 	}
 
-
 	if (globals.retries && globals.delay<=0) {
 		switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "retries set but delay 0 setting to 5000ms\n");
 		globals.delay = 5000;
@@ -338,7 +334,6 @@
 	return status;
 }
 
-
 SWITCH_MODULE_SHUTDOWN_FUNCTION(mod_xml_cdr_shutdown)
 {
 	
@@ -346,8 +341,6 @@
     return SWITCH_STATUS_SUCCESS;
 }
 
-
-
 /* For Emacs:
  * Local Variables:
  * mode:c

Modified: freeswitch/trunk/src/mod/xml_int/mod_xml_curl/mod_xml_curl.c
==============================================================================
--- freeswitch/trunk/src/mod/xml_int/mod_xml_curl/mod_xml_curl.c	(original)
+++ freeswitch/trunk/src/mod/xml_int/mod_xml_curl/mod_xml_curl.c	Sat Jan 26 22:03:09 2008
@@ -81,7 +81,6 @@
 	return SWITCH_STATUS_SUCCESS;
 }
 
-
 static size_t file_callback(void *ptr, size_t size, size_t nmemb, void *data)
 {
 	register unsigned int realsize = (unsigned int) (size * nmemb);
@@ -94,7 +93,6 @@
 	return x;
 }
 
-
 static switch_xml_t xml_url_fetch(const char *section, const char *tag_name, const char *key_name, const char *key_value, switch_event_t *params,
 								  void *user_data)
 {
@@ -129,7 +127,6 @@
 		return xml;
 	}
 
-	
 	switch_snprintf(basic_data, sizeof(basic_data), "hostname=%s&section=%s&tag_name=%s&key_name=%s&key_value=%s",
 					hostname,
 					section,
@@ -285,7 +282,6 @@
 	return x ? SWITCH_STATUS_SUCCESS : SWITCH_STATUS_FALSE;
 }
 
-
 SWITCH_MODULE_LOAD_FUNCTION(mod_xml_curl_load)
 {
 	switch_api_interface_t *xml_curl_api_interface;

Modified: freeswitch/trunk/src/mod/xml_int/mod_xml_rpc/mod_xml_rpc.c
==============================================================================
--- freeswitch/trunk/src/mod/xml_int/mod_xml_rpc/mod_xml_rpc.c	(original)
+++ freeswitch/trunk/src/mod/xml_int/mod_xml_rpc/mod_xml_rpc.c	Sat Jan 26 22:03:09 2008
@@ -104,7 +104,6 @@
 	return SWITCH_STATUS_SUCCESS;
 }
 
-
 SWITCH_MODULE_LOAD_FUNCTION(mod_xml_rpc_load)
 {
 	/* connect my internal structure to the blank pointer passed to me */
@@ -118,7 +117,6 @@
 	return SWITCH_STATUS_SUCCESS;
 }
 
-
 static switch_status_t http_stream_raw_write(switch_stream_handle_t *handle, uint8_t *data, switch_size_t datalen)
 {
 	TSession *r = handle->data;
@@ -147,7 +145,6 @@
 	return ret ? SWITCH_STATUS_FALSE : SWITCH_STATUS_SUCCESS;
 }
 
-
 static abyss_bool http_directory_auth(TSession *r, char *domain_name) 
 {
     char *p, *x;
@@ -227,7 +224,6 @@
 				if (!(x_params = switch_xml_child(x_user, "params"))) {
 					goto authed;
                 }
-
 				
                 for (x_param = switch_xml_child(x_params, "param"); x_param; x_param = x_param->next) {
                     const char *var = switch_xml_attr_soft(x_param, "name");
@@ -307,7 +303,6 @@
 				}
 				goto fail;
 
-
 			authed:
 				
 				ResponseAddField(r, "freeswitch-user", r->user);
@@ -339,8 +334,6 @@
 	char *domain_name, *e;
 	abyss_bool ret = FALSE;
 
-
-
 	if (!strncmp(r->uri, "/domains/", 9)) {
 		domain_name = strdup(r->uri + 9);
 		switch_assert(domain_name);
@@ -373,7 +366,6 @@
 					 SWITCH_GLOBAL_dirs.htdocs_dir, 
 					 new_uri
 					 );
-			
 
 			if (switch_directory_exists(tmp, NULL) == SWITCH_STATUS_SUCCESS) {
 				for (x = 0; x < 2; x++) {
@@ -404,9 +396,7 @@
 				ret = !http_directory_auth(r, NULL);
 			}
 		}
-
 	}
-
 	return ret;
 }
 
@@ -442,7 +432,6 @@
 	if ((path_info = strchr(command, '/'))) {
 		*path_info++ = '\0';
 	}
-	
 
 	for (i=0;i<r->response_headers.size;i++) {
 		ti=&r->response_headers.item[i];
@@ -492,7 +481,6 @@
 
  auth:
 
-
 	if (switch_event_create(&stream.event, SWITCH_EVENT_API) == SWITCH_STATUS_SUCCESS) {
 		const char * const content_length = RequestHeaderValue(r, "content-length");
 			
@@ -557,7 +545,6 @@
 					
 					query = qbuf;
 				}
-
 			}
 			if (query) {
 				switch_event_add_header(stream.event, SWITCH_STACK_BOTTOM, "HTTP-QUERY", "%s", query);
@@ -582,7 +569,6 @@
 					}
 
 					switch_url_decode(q);
-					
 
 					name = q;
 					if ((val = strchr(name, '='))) {
@@ -593,13 +579,10 @@
 				} while (q != NULL);
 			
 				free(qd);
-			
 			}
 		}
 	}
 
-
-
 	//ResponseChunked(r);
 	
 	//ResponseContentType(r, mime);
@@ -609,7 +592,6 @@
 
 	//HTTPWrite(r, "<pre>\n\n", 7);
 
-
 	/* generation of the date field */
 	if (DateToString(&r->date, buf)) {
 		ResponseAddField(r,"Date", buf);
@@ -629,7 +611,6 @@
 		ConnWrite(r->conn, ti->value, (uint32_t)strlen(ti->value));
 		ConnWrite(r->conn,CRLF,2);
 	}
-
 	
 	switch_snprintf(buf, sizeof(buf), "Connection: close\r\n");
 	ConnWrite(r->conn, buf, (uint32_t) strlen(buf));
@@ -656,7 +637,6 @@
 	return ret;
 }
 
-
 static xmlrpc_value *freeswitch_api(xmlrpc_env * const envP, xmlrpc_value * const paramArrayP, void *const userData)
 {
 	char *command = NULL, *arg = NULL;
@@ -744,7 +724,6 @@
 
 SWITCH_MODULE_RUNTIME_FUNCTION(mod_xml_rpc_runtime)
 {
-
 	xmlrpc_registry *registryP;
 	xmlrpc_env env;
 	char logfile[512];
@@ -783,7 +762,6 @@
 		return SWITCH_STATUS_TERM;
 	}
 
-
 	ServerAddHandler(&globals.abyssServer, handler_hook);
 	ServerAddHandler(&globals.abyssServer, auth_hook);
 	switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Starting HTTP Port %d, DocRoot [%s]\n", globals.port, SWITCH_GLOBAL_dirs.htdocs_dir);
@@ -793,11 +771,8 @@
 	return SWITCH_STATUS_TERM;
 }
 
-
-
 SWITCH_MODULE_SHUTDOWN_FUNCTION(mod_xml_rpc_shutdown)
 {
-
 	globals.abyssServer.running = 0;
 	shutdown(globals.abyssServer.listensock, 2);
 	while(globals.running) {



More information about the Freeswitch-svn mailing list