[commit] r9855 - in freeswitch/trunk/src: . mod/applications/mod_commands mod/applications/mod_voicemail mod/asr_tts/mod_openmrcp mod/formats/mod_shout mod/loggers/mod_syslog mod/xml_int/mod_xml_curl mod/xml_int/mod_xml_ldap
Author: brian Date: Mon Oct 6 15:21:59 2008 New Revision: 9855 Modified: freeswitch/trunk/src/mod/applications/mod_commands/mod_commands.c freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c freeswitch/trunk/src/mod/asr_tts/mod_openmrcp/mod_openmrcp.c freeswitch/trunk/src/mod/formats/mod_shout/mod_shout.c freeswitch/trunk/src/mod/loggers/mod_syslog/mod_syslog.c freeswitch/trunk/src/mod/xml_int/mod_xml_curl/mod_xml_curl.c freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldap.c freeswitch/trunk/src/switch_core_port_allocator.c freeswitch/trunk/src/switch_stun.c freeswitch/trunk/src/switch_xml.c Log: if plus a space Modified: freeswitch/trunk/src/mod/applications/mod_commands/mod_commands.c ============================================================================== --- freeswitch/trunk/src/mod/applications/mod_commands/mod_commands.c (original) +++ freeswitch/trunk/src/mod/applications/mod_commands/mod_commands.c Mon Oct 6 15:21:59 2008 @@ -247,7 +247,7 @@ SWITCH_STANDARD_API(module_exists_function) { if (!switch_strlen_zero(cmd)) { - if(switch_loadable_module_exists(cmd) == SWITCH_STATUS_SUCCESS) { + if (switch_loadable_module_exists(cmd) == SWITCH_STATUS_SUCCESS) { stream->write_function(stream, "true"); } else { stream->write_function(stream, "false"); Modified: freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c ============================================================================== --- freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c (original) +++ freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c Mon Oct 6 15:21:59 2008 @@ -2231,7 +2231,7 @@ switch_event_add_header_string(params, SWITCH_STACK_BOTTOM, "voicemail_file_path", file_path); switch_event_add_header_string(params, SWITCH_STACK_BOTTOM, "voicemail_read_flags", read_flags); - if(!switch_strlen_zero(vm_timezone)) { + if (!switch_strlen_zero(vm_timezone)) { char tz_date[80] = ""; if ((switch_strftime_tz(vm_timezone, profile->date_fmt, tz_date, sizeof(tz_date)) == SWITCH_STATUS_SUCCESS) && !switch_strlen_zero_buf(tz_date)) { switch_event_add_header_string(params, SWITCH_STACK_BOTTOM, "voicemail_time", tz_date); Modified: freeswitch/trunk/src/mod/asr_tts/mod_openmrcp/mod_openmrcp.c ============================================================================== --- freeswitch/trunk/src/mod/asr_tts/mod_openmrcp/mod_openmrcp.c (original) +++ freeswitch/trunk/src/mod/asr_tts/mod_openmrcp/mod_openmrcp.c Mon Oct 6 15:21:59 2008 @@ -266,7 +266,7 @@ recognizer_header = mrcp_resource_header_prepare(mrcp_message); - if(!recognizer_header) { + if (!recognizer_header) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Could not prepare resource_header\n"); return MRCP_STATUS_FAILURE; } Modified: freeswitch/trunk/src/mod/formats/mod_shout/mod_shout.c ============================================================================== --- freeswitch/trunk/src/mod/formats/mod_shout/mod_shout.c (original) +++ freeswitch/trunk/src/mod/formats/mod_shout/mod_shout.c Mon Oct 6 15:21:59 2008 @@ -616,6 +616,7 @@ mpg123_param(context->mh, MPG123_FLAGS, MPG123_SEEKBUFFER|MPG123_MONO_MIX, 0); context->stream_url = switch_core_sprintf(context->memory_pool, "http://%s", path); context->prebuf = handle->prebuf; + handle->vol = -4; launch_read_stream_thread(context); } else { mpg123_param(context->mh, MPG123_FLAGS, MPG123_MONO_MIX, 0); Modified: freeswitch/trunk/src/mod/loggers/mod_syslog/mod_syslog.c ============================================================================== --- freeswitch/trunk/src/mod/loggers/mod_syslog/mod_syslog.c (original) +++ freeswitch/trunk/src/mod/loggers/mod_syslog/mod_syslog.c Mon Oct 6 15:21:59 2008 @@ -99,7 +99,7 @@ } /* don't log blank lines */ - if(!switch_strlen_zero(node->data) && (strspn(node->data, " \t\r\n") < strlen(node->data))) { + if (!switch_strlen_zero(node->data) && (strspn(node->data, " \t\r\n") < strlen(node->data))) { syslog(syslog_level, "%s", node->data); } @@ -128,8 +128,7 @@ set_global_format(val); } else if (!strcasecmp(var, "loglevel") && !switch_strlen_zero(val)) { log_level = switch_log_str2level(val); - if(log_level == SWITCH_LOG_INVALID) - { + if (log_level == SWITCH_LOG_INVALID) { log_level = SWITCH_LOG_WARNING; } } 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 Mon Oct 6 15:21:59 2008 @@ -306,12 +306,12 @@ binding->vars_map = vars_map; - if(vars_map) { + if (vars_map) { switch_zmalloc(hash_node,sizeof(hash_node_t)); hash_node->hash = vars_map; hash_node->next = NULL; - if(!globals.hash_root) { + if (!globals.hash_root) { globals.hash_root = hash_node; globals.hash_tail = globals.hash_root; } Modified: freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldap.c ============================================================================== --- freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldap.c (original) +++ freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldap.c Mon Oct 6 15:21:59 2008 @@ -389,7 +389,7 @@ //switch_xml_toxml_buf(xml,buf,0,0,1); //switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "providing:\n%s\n", buf); - if(ret) { + if (ret) { switch_xml_free(xml); return NULL; } Modified: freeswitch/trunk/src/switch_core_port_allocator.c ============================================================================== --- freeswitch/trunk/src/switch_core_port_allocator.c (original) +++ freeswitch/trunk/src/switch_core_port_allocator.c Mon Oct 6 15:21:59 2008 @@ -131,7 +131,9 @@ while (alloc->track[index] && tries < alloc->track_len) { tries++; - if(++index >= alloc->track_len) index = 0; + if (++index >= alloc->track_len) { + index = 0; + } } if (tries < alloc->track_len) { Modified: freeswitch/trunk/src/switch_stun.c ============================================================================== --- freeswitch/trunk/src/switch_stun.c (original) +++ freeswitch/trunk/src/switch_stun.c Mon Oct 6 15:21:59 2008 @@ -538,8 +538,7 @@ switch (attr->type) { case SWITCH_STUN_ATTR_MAPPED_ADDRESS: if (attr->type) { - if(funny) - { + if (funny) { ((switch_stun_ip_t *) attr->value)->address ^= ntohl(0xabcdabcd); } switch_stun_packet_attribute_get_mapped_address(attr, rip, &rport); Modified: freeswitch/trunk/src/switch_xml.c ============================================================================== --- freeswitch/trunk/src/switch_xml.c (original) +++ freeswitch/trunk/src/switch_xml.c Mon Oct 6 15:21:59 2008 @@ -1082,7 +1082,7 @@ pattern = full_path; } - if(glob(pattern, GLOB_NOCHECK, NULL, &glob_data) != 0) { + if (glob(pattern, GLOB_NOCHECK, NULL, &glob_data) != 0) { if (stderr) { fprintf(stderr, "Error including %s\n", pattern); } @@ -1154,7 +1154,7 @@ if ((e = strstr(tcmd, "/>"))) { *e += 2; *e = '\0'; - if(write(write_fd, e, (unsigned) strlen(e)) != (int) strlen(e)) { + if (write(write_fd, e, (unsigned) strlen(e)) != (int) strlen(e)) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Short write!\n"); } } @@ -1223,13 +1223,13 @@ } if ((cmd = strstr(bp, "<!--#"))) { - if(write(write_fd, bp, (unsigned) (cmd - bp)) != (cmd - bp)) { + if (write(write_fd, bp, (unsigned) (cmd - bp)) != (cmd - bp)) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Short write!\n"); } if ((e = strstr(cmd, "-->"))) { *e = '\0'; e += 3; - if(write(write_fd, e, (unsigned) strlen(e)) != (int) strlen(e)) { + if (write(write_fd, e, (unsigned) strlen(e)) != (int) strlen(e)) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Short write!\n"); } } else { @@ -1279,7 +1279,7 @@ continue; } - if(write(write_fd, bp, (unsigned) cur) != (int) cur) { + if (write(write_fd, bp, (unsigned) cur) != (int) cur) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Short write!\n"); } } @@ -2490,7 +2490,7 @@ *pathend = EOS; errno = 0; - if(apr_dir_open (&dirp, pathbuf, pool) != APR_SUCCESS) { + if (apr_dir_open (&dirp, pathbuf, pool) != APR_SUCCESS) { /* TODO: don't call for ENOENT or ENOTDIR? */ apr_pool_destroy(pool); if (pglob->gl_errfunc) { @@ -2510,9 +2510,9 @@ unsigned char *sc; char *dc; - if(apr_dir_read(&dp, APR_FINFO_NAME, dirp) != APR_SUCCESS) + if (apr_dir_read(&dp, APR_FINFO_NAME, dirp) != APR_SUCCESS) break; - if(!(dp.valid & APR_FINFO_NAME) || !(dp.name) || !strlen(dp.name)) + if (!(dp.valid & APR_FINFO_NAME) || !(dp.name) || !strlen(dp.name)) break; /* Initial DOT must be matched literally. */ @@ -2533,7 +2533,7 @@ break; } - if(dirp) + if (dirp) apr_dir_close (dirp); apr_pool_destroy(pool); return(err);
participants (1)
-
Freeswitch SVN