<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[Freeswitch-trunk][15211] </title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<div id="header">FreeSWITCH Subversion</div>
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://fisheye.freeswitch.org/changelog/FreeSWITCH?cs=15211">15211</a></dd>
<dt>Author</dt> <dd>anthm</dd>
<dt>Date</dt> <dd>2009-10-23 11:03:42 -0500 (Fri, 23 Oct 2009)</dd>
</dl>
<h3>Log Message</h3>
<pre>change switch_strlen_zero to zstr</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#freeswitchtrunksrcincludeswitch_utilsh">freeswitch/trunk/src/include/switch_utils.h</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_cidlookupmod_cidlookupc">freeswitch/trunk/src/mod/applications/mod_cidlookup/mod_cidlookup.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_commandsmod_commandsc">freeswitch/trunk/src/mod/applications/mod_commands/mod_commands.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_conferencemod_conferencec">freeswitch/trunk/src/mod/applications/mod_conference/mod_conference.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_curlmod_curlc">freeswitch/trunk/src/mod/applications/mod_curl/mod_curl.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_directorymod_directoryc">freeswitch/trunk/src/mod/applications/mod_directory/mod_directory.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_dptoolsmod_dptoolsc">freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_easyroutemod_easyroutec">freeswitch/trunk/src/mod/applications/mod_easyroute/mod_easyroute.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_enummod_enumc">freeswitch/trunk/src/mod/applications/mod_enum/mod_enum.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_esfmod_esfc">freeswitch/trunk/src/mod/applications/mod_esf/mod_esf.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_exprmod_exprc">freeswitch/trunk/src/mod/applications/mod_expr/mod_expr.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_faxmod_faxc">freeswitch/trunk/src/mod/applications/mod_fax/mod_fax.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_fifomod_fifoc">freeswitch/trunk/src/mod/applications/mod_fifo/mod_fifo.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_lcrmod_lcrc">freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_limitmod_limitc">freeswitch/trunk/src/mod/applications/mod_limit/mod_limit.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_memcachemod_memcachec">freeswitch/trunk/src/mod/applications/mod_memcache/mod_memcache.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_nibblebillmod_nibblebillc">freeswitch/trunk/src/mod/applications/mod_nibblebill/mod_nibblebill.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_rssmod_rssc">freeswitch/trunk/src/mod/applications/mod_rss/mod_rss.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_soundtouchmod_soundtouchcpp">freeswitch/trunk/src/mod/applications/mod_soundtouch/mod_soundtouch.cpp</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_spymod_spyc">freeswitch/trunk/src/mod/applications/mod_spy/mod_spy.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_stressmod_stresscpp">freeswitch/trunk/src/mod/applications/mod_stress/mod_stress.cpp</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_valet_parkingmod_valet_parkingc">freeswitch/trunk/src/mod/applications/mod_valet_parking/mod_valet_parking.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_vmdmod_vmdc">freeswitch/trunk/src/mod/applications/mod_vmd/mod_vmd.c</a></li>
<li><a href="#freeswitchtrunksrcmodapplicationsmod_voicemailmod_voicemailc">freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c</a></li>
<li><a href="#freeswitchtrunksrcmodasr_ttsmod_cepstralmod_cepstralc">freeswitch/trunk/src/mod/asr_tts/mod_cepstral/mod_cepstral.c</a></li>
<li><a href="#freeswitchtrunksrcmodasr_ttsmod_pocketsphinxmod_pocketsphinxc">freeswitch/trunk/src/mod/asr_tts/mod_pocketsphinx/mod_pocketsphinx.c</a></li>
<li><a href="#freeswitchtrunksrcmodasr_ttsmod_tts_commandlinemod_tts_commandlinec">freeswitch/trunk/src/mod/asr_tts/mod_tts_commandline/mod_tts_commandline.c</a></li>
<li><a href="#freeswitchtrunksrcmodasr_ttsmod_unimrcpmod_unimrcpc">freeswitch/trunk/src/mod/asr_tts/mod_unimrcp/mod_unimrcp.c</a></li>
<li><a href="#freeswitchtrunksrcmoddialplansmod_dialplan_asteriskmod_dialplan_asteriskc">freeswitch/trunk/src/mod/dialplans/mod_dialplan_asterisk/mod_dialplan_asterisk.c</a></li>
<li><a href="#freeswitchtrunksrcmoddialplansmod_dialplan_xmlmod_dialplan_xmlc">freeswitch/trunk/src/mod/dialplans/mod_dialplan_xml/mod_dialplan_xml.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_alsamod_alsac">freeswitch/trunk/src/mod/endpoints/mod_alsa/mod_alsa.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_dingalingmod_dingalingc">freeswitch/trunk/src/mod/endpoints/mod_dingaling/mod_dingaling.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_loopbackmod_loopbackc">freeswitch/trunk/src/mod/endpoints/mod_loopback/mod_loopback.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_portaudiomod_portaudioc">freeswitch/trunk/src/mod/endpoints/mod_portaudio/mod_portaudio.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_skypiaxmod_skypiaxc">freeswitch/trunk/src/mod/endpoints/mod_skypiax/mod_skypiax.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_sofiamod_sofiac">freeswitch/trunk/src/mod/endpoints/mod_sofia/mod_sofia.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_sofiamod_sofiah">freeswitch/trunk/src/mod/endpoints/mod_sofia/mod_sofia.h</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_sofiasofiac">freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_sofiasofia_gluec">freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_glue.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_sofiasofia_presencec">freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c</a></li>
<li><a href="#freeswitchtrunksrcmodendpointsmod_sofiasofia_regc">freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_reg.c</a></li>
<li><a href="#freeswitchtrunksrcmodevent_handlersmod_cdr_csvmod_cdr_csvc">freeswitch/trunk/src/mod/event_handlers/mod_cdr_csv/mod_cdr_csv.c</a></li>
<li><a href="#freeswitchtrunksrcmodevent_handlersmod_erlang_eventei_helpersc">freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/ei_helpers.c</a></li>
<li><a href="#freeswitchtrunksrcmodevent_handlersmod_erlang_eventhandle_msgc">freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/handle_msg.c</a></li>
<li><a href="#freeswitchtrunksrcmodevent_handlersmod_erlang_eventmod_erlang_eventc">freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/mod_erlang_event.c</a></li>
<li><a href="#freeswitchtrunksrcmodevent_handlersmod_event_socketmod_event_socketc">freeswitch/trunk/src/mod/event_handlers/mod_event_socket/mod_event_socket.c</a></li>
<li><a href="#freeswitchtrunksrcmodformatsmod_local_streammod_local_streamc">freeswitch/trunk/src/mod/formats/mod_local_stream/mod_local_stream.c</a></li>
<li><a href="#freeswitchtrunksrcmodformatsmod_portaudio_streammod_portaudio_streamc">freeswitch/trunk/src/mod/formats/mod_portaudio_stream/mod_portaudio_stream.c</a></li>
<li><a href="#freeswitchtrunksrcmodlanguagesmod_luafreeswitch_luacpp">freeswitch/trunk/src/mod/languages/mod_lua/freeswitch_lua.cpp</a></li>
<li><a href="#freeswitchtrunksrcmodlanguagesmod_luamod_luacpp">freeswitch/trunk/src/mod/languages/mod_lua/mod_lua.cpp</a></li>
<li><a href="#freeswitchtrunksrcmodlanguagesmod_managedmod_managedcpp">freeswitch/trunk/src/mod/languages/mod_managed/mod_managed.cpp</a></li>
<li><a href="#freeswitchtrunksrcmodlanguagesmod_perlmod_perlc">freeswitch/trunk/src/mod/languages/mod_perl/mod_perl.c</a></li>
<li><a href="#freeswitchtrunksrcmodlanguagesmod_pythonmod_pythonc">freeswitch/trunk/src/mod/languages/mod_python/mod_python.c</a></li>
<li><a href="#freeswitchtrunksrcmodlanguagesmod_spidermonkeymod_spidermonkeyc">freeswitch/trunk/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c</a></li>
<li><a href="#freeswitchtrunksrcmodlanguagesmod_spidermonkey_curlmod_spidermonkey_curlc">freeswitch/trunk/src/mod/languages/mod_spidermonkey_curl/mod_spidermonkey_curl.c</a></li>
<li><a href="#freeswitchtrunksrcmodlanguagesmod_spidermonkey_odbcmod_spidermonkey_odbcc">freeswitch/trunk/src/mod/languages/mod_spidermonkey_odbc/mod_spidermonkey_odbc.c</a></li>
<li><a href="#freeswitchtrunksrcmodlanguagesmod_yamlmod_yamlc">freeswitch/trunk/src/mod/languages/mod_yaml/mod_yaml.c</a></li>
<li><a href="#freeswitchtrunksrcmodloggersmod_consolemod_consolec">freeswitch/trunk/src/mod/loggers/mod_console/mod_console.c</a></li>
<li><a href="#freeswitchtrunksrcmodloggersmod_logfilemod_logfilec">freeswitch/trunk/src/mod/loggers/mod_logfile/mod_logfile.c</a></li>
<li><a href="#freeswitchtrunksrcmodloggersmod_syslogmod_syslogc">freeswitch/trunk/src/mod/loggers/mod_syslog/mod_syslog.c</a></li>
<li><a href="#freeswitchtrunksrcmodxml_intmod_xml_cdrmod_xml_cdrc">freeswitch/trunk/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c</a></li>
<li><a href="#freeswitchtrunksrcmodxml_intmod_xml_curlmod_xml_curlc">freeswitch/trunk/src/mod/xml_int/mod_xml_curl/mod_xml_curl.c</a></li>
<li><a href="#freeswitchtrunksrcmodxml_intmod_xml_ldapmod_xml_ldapc">freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldap.c</a></li>
<li><a href="#freeswitchtrunksrcmodxml_intmod_xml_ldapmod_xml_ldapv2c">freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldapv2.c</a></li>
<li><a href="#freeswitchtrunksrcmodxml_intmod_xml_rpcmod_xml_rpcc">freeswitch/trunk/src/mod/xml_int/mod_xml_rpc/mod_xml_rpc.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_callerc">freeswitch/trunk/src/switch_caller.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_channelc">freeswitch/trunk/src/switch_channel.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_consolec">freeswitch/trunk/src/switch_console.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_corec">freeswitch/trunk/src/switch_core.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_core_asrc">freeswitch/trunk/src/switch_core_asr.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_core_filec">freeswitch/trunk/src/switch_core_file.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_core_ioc">freeswitch/trunk/src/switch_core_io.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_core_memoryc">freeswitch/trunk/src/switch_core_memory.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_core_sessionc">freeswitch/trunk/src/switch_core_session.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_core_speechc">freeswitch/trunk/src/switch_core_speech.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_core_sqldbc">freeswitch/trunk/src/switch_core_sqldb.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_core_state_machinec">freeswitch/trunk/src/switch_core_state_machine.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_cppcpp">freeswitch/trunk/src/switch_cpp.cpp</a></li>
<li><a href="#freeswitchtrunksrcswitch_eventc">freeswitch/trunk/src/switch_event.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_ivrc">freeswitch/trunk/src/switch_ivr.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_ivr_asyncc">freeswitch/trunk/src/switch_ivr_async.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_ivr_bridgec">freeswitch/trunk/src/switch_ivr_bridge.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_ivr_menuc">freeswitch/trunk/src/switch_ivr_menu.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_ivr_originatec">freeswitch/trunk/src/switch_ivr_originate.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_ivr_play_sayc">freeswitch/trunk/src/switch_ivr_play_say.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_loadable_modulec">freeswitch/trunk/src/switch_loadable_module.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_logc">freeswitch/trunk/src/switch_log.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_natc">freeswitch/trunk/src/switch_nat.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_odbcc">freeswitch/trunk/src/switch_odbc.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_rtpc">freeswitch/trunk/src/switch_rtp.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_schedulerc">freeswitch/trunk/src/switch_scheduler.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_swigc">freeswitch/trunk/src/switch_swig.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_timec">freeswitch/trunk/src/switch_time.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_utilsc">freeswitch/trunk/src/switch_utils.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_xmlc">freeswitch/trunk/src/switch_xml.c</a></li>
<li><a href="#freeswitchtrunksrcswitch_xml_configc">freeswitch/trunk/src/switch_xml_config.c</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="freeswitchtrunksrcincludeswitch_utilsh"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/include/switch_utils.h (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/include/switch_utils.h        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/include/switch_utils.h        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -74,11 +74,11 @@
</span><span class="cx"> \param s the string to test
</span><span class="cx"> \return true value if the string is NULL or zero length
</span><span class="cx"> */
</span><del>-#define switch_strlen_zero(s) (!s || *(s) == '\0')
-#define switch_strlen_zero_buf(s) (*(s) == '\0')
</del><ins>+#define zstr(s) (!s || *(s) == '\0')
+#define zstr_buf(s) (*(s) == '\0')
</ins><span class="cx"> static inline switch_bool_t switch_is_moh(const char *s)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(s) || !strcasecmp(s, "silence") || !strcasecmp(s, "indicate_hold")) {
</del><ins>+        if (zstr(s) || !strcasecmp(s, "silence") || !strcasecmp(s, "indicate_hold")) {
</ins><span class="cx">                 return SWITCH_FALSE;
</span><span class="cx">         }
</span><span class="cx">         return SWITCH_TRUE;
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_cidlookupmod_cidlookupc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_cidlookup/mod_cidlookup.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_cidlookup/mod_cidlookup.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_cidlookup/mod_cidlookup.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -98,7 +98,7 @@
</span><span class="cx">         
</span><span class="cx">         if ((callback_type == CONFIG_LOAD || callback_type == CONFIG_RELOAD) && changed) {
</span><span class="cx">
</span><del>-                if(switch_strlen_zero(newvalue)) {
</del><ins>+                if(zstr(newvalue)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "No local database defined.\n");
</span><span class="cx">                 } else {
</span><span class="cx">                         odbc_dsn = strdup(newvalue);
</span><span class="lines">@@ -325,7 +325,7 @@
</span><span class="cx">         curl_easy_cleanup(curl_handle);
</span><span class="cx">         
</span><span class="cx">         if (        http_data.stream.data &&
</span><del>-                        !switch_strlen_zero((char *)http_data.stream.data) &&
</del><ins>+                        !zstr((char *)http_data.stream.data) &&
</ins><span class="cx">                         strcmp(" ", http_data.stream.data) ) {
</span><span class="cx">                 
</span><span class="cx">                 name = switch_core_strdup(pool, http_data.stream.data);
</span><span class="lines">@@ -564,7 +564,7 @@
</span><span class="cx">         switch_bool_t skipurl = SWITCH_FALSE;
</span><span class="cx">         switch_bool_t skipcitystate = SWITCH_FALSE;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 switch_goto_status(SWITCH_STATUS_SUCCESS, usage);
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_commandsmod_commandsc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_commands/mod_commands.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_commands/mod_commands.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_commands/mod_commands.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -49,7 +49,7 @@
</span><span class="cx"> {
</span><span class="cx">         char host[256] = "";
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "%s", "parameter missing\n");
</span><span class="cx">         } else {
</span><span class="cx">                 if (switch_resolve_host(cmd, host, sizeof(host)) == SWITCH_STATUS_SUCCESS) {
</span><span class="lines">@@ -146,7 +146,7 @@
</span><span class="cx">         int diff;
</span><span class="cx">         int max = 10;
</span><span class="cx">         char *p;
</span><del>-        if (switch_strlen_zero(cmd)){
</del><ins>+        if (zstr(cmd)){
</ins><span class="cx">                 stream->write_function(stream, "parameter missing\n");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -189,7 +189,7 @@
</span><span class="cx">         char *fp = NULL;
</span><span class="cx">         const char *call_delim = ",";
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -224,7 +224,7 @@
</span><span class="cx">                 domain = switch_core_get_variable("domain");
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(domain)) {
</del><ins>+        if (!zstr(domain)) {
</ins><span class="cx">                 switch_xml_t xml, x_domain, x_group;
</span><span class="cx">                 switch_event_t *params;
</span><span class="cx">                 switch_stream_handle_t dstream = { 0 };
</span><span class="lines">@@ -377,7 +377,7 @@
</span><span class="cx">         const char *rval = "false";
</span><span class="cx">         char *group;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(cmd) || !(mydata = strdup(cmd))) {
</del><ins>+        if (zstr(cmd) || !(mydata = strdup(cmd))) {
</ins><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -427,7 +427,7 @@
</span><span class="cx">         const char *container = "params", *elem = "param";
</span><span class="cx">         switch_event_t *params = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || !(mydata = strdup(cmd))) {
</del><ins>+        if (zstr(cmd) || !(mydata = strdup(cmd))) {
</ins><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -580,7 +580,7 @@
</span><span class="cx"> {
</span><span class="cx">         char digest[SWITCH_MD5_DIGEST_STRING_SIZE] = { 0 };
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "%s", "!err!");
</span><span class="cx">         } else {
</span><span class="cx">                 switch_md5_string(digest, (void *) cmd, strlen(cmd));
</span><span class="lines">@@ -595,7 +595,7 @@
</span><span class="cx">         char *reply = "";
</span><span class="cx">         char *data = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 data = strdup(cmd);
</span><span class="cx">                 switch_url_decode(data);
</span><span class="cx">                 reply = data;
</span><span class="lines">@@ -627,7 +627,7 @@
</span><span class="cx">
</span><span class="cx">         ip = ip_buf;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "%s", "-STUN Failed! NO STUN SERVER\n");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -658,7 +658,7 @@
</span><span class="cx">
</span><span class="cx">         switch_core_new_memory_pool(&pool);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(stun_ip)) {
</del><ins>+        if (zstr(stun_ip)) {
</ins><span class="cx">                 stream->write_function(stream, "%s", "-STUN Failed! NO STUN SERVER\n");
</span><span class="cx">         } else {
</span><span class="cx">                 if ((switch_stun_lookup(&ip, &port, stun_ip, stun_port, &error, pool)) == SWITCH_STATUS_SUCCESS && ip && port) {
</span><span class="lines">@@ -684,7 +684,7 @@
</span><span class="cx">         switch_core_session_t *xsession;
</span><span class="cx">         char uuid[80] = "";
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR, no input\n");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -699,7 +699,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(mycmd)) {
</del><ins>+        if (zstr(mycmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR, no input\n");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -739,7 +739,7 @@
</span><span class="cx">         char uuid[80] = "";
</span><span class="cx">         const char *p, *input = cmd;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "%s", "");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -751,7 +751,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(input)) {
</del><ins>+        if (zstr(input)) {
</ins><span class="cx">                 stream->write_function(stream, "%s", "");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -778,7 +778,7 @@
</span><span class="cx">
</span><span class="cx"> SWITCH_STANDARD_API(module_exists_function)
</span><span class="cx"> {
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 if (switch_loadable_module_exists(cmd) == SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                         stream->write_function(stream, "true");
</span><span class="cx">                 } else {
</span><span class="lines">@@ -793,7 +793,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_xml_t root = NULL, domain = NULL;
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(cmd)) {        
</del><ins>+        if (!zstr(cmd)) {        
</ins><span class="cx">                 if (switch_xml_locate_domain(cmd, NULL, &root, &domain) == SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                         stream->write_function(stream, "true");
</span><span class="cx">                         switch_xml_free(root);
</span><span class="lines">@@ -811,7 +811,7 @@
</span><span class="cx">         char *data = NULL;
</span><span class="cx">         int len = 0 ;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 len = (strlen(cmd) * 3) + 1;
</span><span class="cx">                 switch_zmalloc(data, len);
</span><span class="cx">                 switch_url_encode(cmd, data, len);
</span><span class="lines">@@ -1249,7 +1249,7 @@
</span><span class="cx">         char *mydata, *argv[5];
</span><span class="cx">         int32_t arg = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", CTL_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -1374,7 +1374,7 @@
</span><span class="cx"> {
</span><span class="cx">         const char *err;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", LOAD_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -1395,7 +1395,7 @@
</span><span class="cx">         switch_bool_t force = SWITCH_FALSE;
</span><span class="cx">         const char *p = cmd;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", UNLOAD_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -1419,7 +1419,7 @@
</span><span class="cx">         }
</span><span class="cx"> end:
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", UNLOAD_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -1439,7 +1439,7 @@
</span><span class="cx">         switch_bool_t force = SWITCH_FALSE;
</span><span class="cx">         const char *p = cmd;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", UNLOAD_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -1462,7 +1462,7 @@
</span><span class="cx">         }
</span><span class="cx"> end:
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", UNLOAD_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -1504,7 +1504,7 @@
</span><span class="cx">         char *mycmd = NULL, *kcause = NULL;
</span><span class="cx">         switch_call_cause_t cause = SWITCH_CAUSE_NORMAL_CLEARING;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || !(mycmd = strdup(cmd))) {
</del><ins>+        if (zstr(cmd) || !(mycmd = strdup(cmd))) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", KILL_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -1513,11 +1513,11 @@
</span><span class="cx">                 *kcause++ = '\0';
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(mycmd) || !(ksession = switch_core_session_locate(mycmd))) {
</del><ins>+        if (zstr(mycmd) || !(ksession = switch_core_session_locate(mycmd))) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR No Such Channel!\n");
</span><span class="cx">         } else {
</span><span class="cx">                 switch_channel_t *channel = switch_core_session_get_channel(ksession);
</span><del>-                if (!switch_strlen_zero(kcause)){
</del><ins>+                if (!zstr(kcause)){
</ins><span class="cx">                         cause = switch_channel_str2cause(kcause);
</span><span class="cx">                 }
</span><span class="cx">                 switch_channel_hangup(channel, cause);
</span><span class="lines">@@ -1536,7 +1536,7 @@
</span><span class="cx">         char *mycmd = NULL, *argv[3] = { 0 };
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || !(mycmd = strdup(cmd))) {
</del><ins>+        if (zstr(cmd) || !(mycmd = strdup(cmd))) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1590,7 +1590,7 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">         char *tuuid, *dest, *dp, *context, *arg = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || !(mycmd = strdup(cmd))) {
</del><ins>+        if (zstr(cmd) || !(mycmd = strdup(cmd))) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", TRANSFER_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -1606,7 +1606,7 @@
</span><span class="cx">         dp = argv[2];
</span><span class="cx">         context = argv[3];
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(tuuid) || !(tsession = switch_core_session_locate(tuuid))) {
</del><ins>+        if (zstr(tuuid) || !(tsession = switch_core_session_locate(tuuid))) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR No Such Channel!\n");
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -1734,13 +1734,13 @@
</span><span class="cx">         switch_core_session_t *tsession = NULL;
</span><span class="cx">         char *uuid = NULL, *text = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (uuid = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (uuid = strdup(cmd))) {
</ins><span class="cx">                 if ((text = strchr(uuid, ' '))) {
</span><span class="cx">                         *text++ = '\0';
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(uuid) || switch_strlen_zero(text)) {
</del><ins>+        if (zstr(uuid) || zstr(text)) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", UUID_CHAT_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 if ((tsession = switch_core_session_locate(uuid))) {
</span><span class="lines">@@ -1772,13 +1772,13 @@
</span><span class="cx">         switch_core_session_t *tsession = NULL;
</span><span class="cx">         char *uuid = NULL, *text = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (uuid = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (uuid = strdup(cmd))) {
</ins><span class="cx">                 if ((text = strchr(uuid, ' '))) {
</span><span class="cx">                         *text++ = '\0';
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(uuid) || switch_strlen_zero(text)) {
</del><ins>+        if (zstr(uuid) || zstr(text)) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", UUID_DEFLECT_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 if ((tsession = switch_core_session_locate(uuid))) {
</span><span class="lines">@@ -1807,11 +1807,11 @@
</span><span class="cx">         char *mycmd = NULL, *argv[6] = { 0 };
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || argc < 2 || argc > 5 || switch_strlen_zero(argv[0])) {
</del><ins>+        if (zstr(cmd) || argc < 2 || argc > 5 || zstr(argv[0])) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", SCHED_TRANSFER_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 char *uuid = argv[1];
</span><span class="lines">@@ -1846,11 +1846,11 @@
</span><span class="cx">         char *mycmd = NULL, *argv[4] = { 0 };
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || argc < 1 || switch_strlen_zero(argv[0])) {
</del><ins>+        if (zstr(cmd) || argc < 1 || zstr(argv[0])) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", SCHED_HANGUP_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 char *uuid = argv[1];
</span><span class="lines">@@ -1888,11 +1888,11 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || argc < 1 || switch_strlen_zero(argv[0])) {
</del><ins>+        if (zstr(cmd) || argc < 1 || zstr(argv[0])) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", MEDIA_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 if (!strcasecmp(argv[0], "off")) {
</span><span class="lines">@@ -1919,11 +1919,11 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || argc < 2) {
</del><ins>+        if (zstr(cmd) || argc < 2) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", BROADCAST_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 switch_media_flag_t flags = SMF_NONE;
</span><span class="lines">@@ -1955,11 +1955,11 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || argc < 3 || switch_strlen_zero(argv[0])) {
</del><ins>+        if (zstr(cmd) || argc < 3 || zstr(argv[0])) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", SCHED_BROADCAST_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 switch_media_flag_t flags = SMF_NONE;
</span><span class="lines">@@ -1998,11 +1998,11 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || argc < 1 || switch_strlen_zero(argv[0])) {
</del><ins>+        if (zstr(cmd) || argc < 1 || zstr(argv[0])) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", HOLD_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 if (!strcasecmp(argv[0], "off")) {
</span><span class="lines">@@ -2029,11 +2029,11 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || argc < 2 || switch_strlen_zero(argv[0]) || switch_strlen_zero(argv[1])) {
</del><ins>+        if (zstr(cmd) || argc < 2 || zstr(argv[0]) || zstr(argv[1])) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", DISPLAY_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 switch_core_session_message_t msg = { 0 };
</span><span class="lines">@@ -2065,11 +2065,11 @@
</span><span class="cx">         char *mycmd = NULL, *argv[4] = { 0 };
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || argc < 2) {
</del><ins>+        if (zstr(cmd) || argc < 2) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", UUID_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 switch_status_t status;
</span><span class="lines">@@ -2105,7 +2105,7 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">         uint32_t limit = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2122,7 +2122,7 @@
</span><span class="cx">         path = argv[2];
</span><span class="cx">         limit = argv[3] ? atoi(argv[3]) : 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(uuid) || switch_strlen_zero(action) || switch_strlen_zero(path)) {
</del><ins>+        if (zstr(uuid) || zstr(action) || zstr(path)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2171,7 +2171,7 @@
</span><span class="cx">         uint32_t limit = 0;
</span><span class="cx">         char *flags = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || !(mycmd = strdup(cmd))) {
</del><ins>+        if (zstr(cmd) || !(mycmd = strdup(cmd))) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2185,7 +2185,7 @@
</span><span class="cx">         limit = argv[3] ? atoi(argv[3]) : 0;
</span><span class="cx">         flags = argv[4];
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(uuid) || switch_strlen_zero(action) || switch_strlen_zero(path)) {
</del><ins>+        if (zstr(uuid) || zstr(action) || zstr(path)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2232,7 +2232,7 @@
</span><span class="cx">         switch_channel_t *channel = NULL;
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", BREAK_SYNTAX);
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -2277,11 +2277,11 @@
</span><span class="cx">         char *mycmd = NULL, *argv[4] = { 0 };
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || argc < 2 || switch_strlen_zero(argv[0])) {
</del><ins>+        if (zstr(cmd) || argc < 2 || zstr(argv[0])) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", PAUSE_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 char *uuid = argv[0];
</span><span class="lines">@@ -2320,7 +2320,7 @@
</span><span class="cx">         uint8_t machine = 1;
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">
</span><del>-        if (session || switch_strlen_zero(cmd)) {
</del><ins>+        if (session || zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-USAGE %s\n", ORIGINATE_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -3000,7 +3000,7 @@
</span><span class="cx">         /* switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "SQL: %s.\n", sql); */
</span><span class="cx">         
</span><span class="cx">         if (!strcasecmp(as, "delim") || !strcasecmp(as, "csv")) {
</span><del>-                if (switch_strlen_zero(holder.delim)) {
</del><ins>+                if (zstr(holder.delim)) {
</ins><span class="cx">                         if (!(holder.delim = argv[3])) {
</span><span class="cx">                                 holder.delim = ",";
</span><span class="cx">                         }
</span><span class="lines">@@ -3075,7 +3075,7 @@
</span><span class="cx"> {
</span><span class="cx">         char showcmd[1024];
</span><span class="cx">         int all = 0;
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 sprintf(showcmd, "help");
</span><span class="cx">                 all = 1;
</span><span class="cx">         } else {
</span><span class="lines">@@ -3100,7 +3100,7 @@
</span><span class="cx">         switch_core_session_t *l_session = NULL;
</span><span class="cx">         int x = 0, sched = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || !(mycmd = strdup(cmd))) {
</del><ins>+        if (zstr(cmd) || !(mycmd = strdup(cmd))) {
</ins><span class="cx">                 goto error;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -3158,7 +3158,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_core_session_t *fsession;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (fsession = switch_core_session_locate(cmd))) {
</del><ins>+        if (!zstr(cmd) && (fsession = switch_core_session_locate(cmd))) {
</ins><span class="cx">                 switch_channel_flush_dtmf(switch_core_session_get_channel(fsession));
</span><span class="cx">                 switch_core_session_rwunlock(fsession);
</span><span class="cx">                 stream->write_function(stream, "+OK\n");
</span><span class="lines">@@ -3176,9 +3176,9 @@
</span><span class="cx">         char *mycmd = NULL, *argv[3] = { 0 };
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><del>-                if ((argc == 2 || argc == 3) && !switch_strlen_zero(argv[0])) {
</del><ins>+                if ((argc == 2 || argc == 3) && !zstr(argv[0])) {
</ins><span class="cx">                         char *uuid = argv[0];
</span><span class="cx">                         char *var_name = argv[1];
</span><span class="cx">                         char *var_value = NULL;
</span><span class="lines">@@ -3191,7 +3191,7 @@
</span><span class="cx">                                 switch_channel_t *channel;
</span><span class="cx">                                 channel = switch_core_session_get_channel(psession);
</span><span class="cx">
</span><del>-                                if (switch_strlen_zero(var_name)) {
</del><ins>+                                if (zstr(var_name)) {
</ins><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No variable name specified.\n");
</span><span class="cx">                                         stream->write_function(stream, "-ERR No variable specified\n");
</span><span class="cx">                                 } else {
</span><span class="lines">@@ -3224,7 +3224,7 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">         char *var_name, *var_value = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 char *uuid = mycmd;
</span><span class="cx">                 if (!(vars = strchr(uuid, ' '))) {
</span><span class="cx">                         goto done;
</span><span class="lines">@@ -3241,7 +3241,7 @@
</span><span class="cx">                                 if (var_name && (var_value = strchr(var_name, '='))) {
</span><span class="cx">                                         *var_value++ = '\0';
</span><span class="cx">                                 }
</span><del>-                                if (switch_strlen_zero(var_name)) {
</del><ins>+                                if (zstr(var_name)) {
</ins><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No variable name specified.\n");
</span><span class="cx">                                         stream->write_function(stream, "-ERR No variable specified\n");
</span><span class="cx">                                 } else {
</span><span class="lines">@@ -3289,9 +3289,9 @@
</span><span class="cx">         char *mycmd = NULL, *argv[4] = { 0 };
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><del>-                if (argc >= 2 && !switch_strlen_zero(argv[0])) {
</del><ins>+                if (argc >= 2 && !zstr(argv[0])) {
</ins><span class="cx">                         char *uuid = argv[0];
</span><span class="cx">                         char *var_name = argv[1];
</span><span class="cx">                         const char *var_value = NULL;
</span><span class="lines">@@ -3300,7 +3300,7 @@
</span><span class="cx">                                 switch_channel_t *channel;
</span><span class="cx">                                 channel = switch_core_session_get_channel(psession);
</span><span class="cx">
</span><del>-                                if (switch_strlen_zero(var_name)) {
</del><ins>+                                if (zstr(var_name)) {
</ins><span class="cx">                                         stream->write_function(stream, "-ERR No variable name specified!\n");
</span><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No variable name specified.\n");
</span><span class="cx">                                 } else {
</span><span class="lines">@@ -3336,7 +3336,7 @@
</span><span class="cx">         char *uuid = NULL, *dtmf_data = NULL;
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -3350,7 +3350,7 @@
</span><span class="cx">
</span><span class="cx">         uuid = argv[0];
</span><span class="cx">         dtmf_data = argv[1];
</span><del>-        if (switch_strlen_zero(uuid) || switch_strlen_zero(dtmf_data)) {
</del><ins>+        if (zstr(uuid) || zstr(dtmf_data)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -3381,9 +3381,9 @@
</span><span class="cx">         char *mycmd = NULL, *argv[4] = { 0 };
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><del>-                if (argc >= 0 && !switch_strlen_zero(argv[0])) {
</del><ins>+                if (argc >= 0 && !zstr(argv[0])) {
</ins><span class="cx">                         char *uuid = argv[0];
</span><span class="cx">                         char *format = argv[1];
</span><span class="cx">
</span><span class="lines">@@ -3445,13 +3445,13 @@
</span><span class="cx">         char *mycmd = NULL, *argv[2] = { 0 };
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, '=', argv, (sizeof(argv) / sizeof(argv[0])));
</span><del>-                if (argc > 0 && !switch_strlen_zero(argv[0])) {
</del><ins>+                if (argc > 0 && !zstr(argv[0])) {
</ins><span class="cx">                         char *var_name = argv[0];
</span><span class="cx">                         char *var_value = argv[1];
</span><span class="cx">
</span><del>-                        if (switch_strlen_zero(var_value)) {
</del><ins>+                        if (zstr(var_value)) {
</ins><span class="cx">                                 var_value = NULL;
</span><span class="cx">                         }
</span><span class="cx">                         switch_core_set_variable(var_name, var_value);
</span><span class="lines">@@ -3470,7 +3470,7 @@
</span><span class="cx"> #define GLOBAL_GETVAR_SYNTAX "<var>"
</span><span class="cx"> SWITCH_STANDARD_API(global_getvar_function)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 switch_core_dump_variables(stream);
</span><span class="cx">         } else {
</span><span class="cx">                 stream->write_function(stream, "%s", switch_str_nil(switch_core_get_variable(cmd)));
</span><span class="lines">@@ -3481,7 +3481,7 @@
</span><span class="cx"> #define SYSTEM_SYNTAX "<command>"
</span><span class="cx"> SWITCH_STANDARD_API(system_function)
</span><span class="cx"> {
</span><del>- if (switch_strlen_zero(cmd)) {
</del><ins>+ if (zstr(cmd)) {
</ins><span class="cx"> stream->write_function(stream, "-USAGE: %s\n", SYSTEM_SYNTAX);
</span><span class="cx"> return SWITCH_STATUS_SUCCESS;
</span><span class="cx"> }
</span><span class="lines">@@ -3498,7 +3498,7 @@
</span><span class="cx"> #define SYSTEM_SYNTAX "<command>"
</span><span class="cx"> SWITCH_STANDARD_API(bg_system_function)
</span><span class="cx"> {
</span><del>- if (switch_strlen_zero(cmd)) {
</del><ins>+ if (zstr(cmd)) {
</ins><span class="cx"> stream->write_function(stream, "-USAGE: %s\n", SYSTEM_SYNTAX);
</span><span class="cx"> return SWITCH_STATUS_SUCCESS;
</span><span class="cx"> }
</span><span class="lines">@@ -3517,7 +3517,7 @@
</span><span class="cx">         const char *tz_name = NULL;
</span><span class="cx">         char date[80] = "";
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 format = strchr(cmd, ' ');
</span><span class="cx">                 tz_name = cmd;
</span><span class="cx">                 if (format) {
</span><span class="lines">@@ -3542,7 +3542,7 @@
</span><span class="cx">         char *val = NULL;
</span><span class="cx">         switch_call_cause_t cause = SWITCH_CAUSE_MANAGER_REQUEST;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">                 switch_assert(argv[0]);
</span><span class="cx">                 if ((cause = switch_channel_str2cause(argv[0])) == SWITCH_CAUSE_NONE) {
</span><span class="lines">@@ -3556,13 +3556,13 @@
</span><span class="cx">                 var = NULL;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(var)) {
</del><ins>+        if (zstr(var)) {
</ins><span class="cx">                 switch_core_session_hupall(cause);
</span><span class="cx">         } else {
</span><span class="cx">                 switch_core_session_hupall_matching_var(var, val, cause);
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(var)) {
</del><ins>+        if (zstr(var)) {
</ins><span class="cx">                 stream->write_function(stream, "+OK hangup all channels with cause %s\n", switch_channel_cause2str(cause));
</span><span class="cx">         } else {
</span><span class="cx">                 stream->write_function(stream, "+OK hangup all channels matching [%s]=[%s] with cause: %s\n", var, val, switch_channel_cause2str(cause));
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_conferencemod_conferencec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_conference/mod_conference.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_conference/mod_conference.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_conference/mod_conference.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -676,7 +676,7 @@
</span><span class="cx">                         switch_snprintf(saymsg, sizeof(saymsg), "Auto Calling %d parties", call_list->itteration);
</span><span class="cx">                         conference_member_say(member, saymsg, 0);
</span><span class="cx">                 } else {
</span><del>-                        if (switch_strlen_zero(conference->special_announce)) {
</del><ins>+                        if (zstr(conference->special_announce)) {
</ins><span class="cx">                                 /* announce the total number of members in the conference */
</span><span class="cx">                                 if (conference->count >= conference->announce_count && conference->announce_count > 1) {
</span><span class="cx">                                         switch_snprintf(msg, sizeof(msg), "There are %d callers", conference->count);
</span><span class="lines">@@ -1882,7 +1882,7 @@
</span><span class="cx">                                                 
</span><span class="cx">                                                 if (switch_test_flag(member, MFLAG_MUTE_DETECT) && !switch_test_flag(member, MFLAG_CAN_SPEAK)) {
</span><span class="cx">
</span><del>-                                                        if (!switch_strlen_zero(member->conference->mute_detect_sound)) {
</del><ins>+                                                        if (!zstr(member->conference->mute_detect_sound)) {
</ins><span class="cx">                                                                 conference_member_play_file(member, member->conference->mute_detect_sound, 0);
</span><span class="cx">                                                         }
</span><span class="cx">
</span><span class="lines">@@ -2782,7 +2782,7 @@
</span><span class="cx">                 expanded = NULL;
</span><span class="cx">         }
</span><span class="cx">         if (!strncasecmp(file, "say:", 4)) {
</span><del>-                if (!switch_strlen_zero(file + 4)) {
</del><ins>+                if (!zstr(file + 4)) {
</ins><span class="cx">                         status = conference_member_say(member, file + 4, leadin);
</span><span class="cx">                 }
</span><span class="cx">                 goto done;
</span><span class="lines">@@ -2793,7 +2793,7 @@
</span><span class="cx">                                 goto done;
</span><span class="cx">                         }
</span><span class="cx">                         file = dfile;
</span><del>-                } else if (!switch_strlen_zero(file)) {
</del><ins>+                } else if (!zstr(file)) {
</ins><span class="cx">                         status = conference_member_say(member, file, leadin);
</span><span class="cx">                         goto done;
</span><span class="cx">                 }
</span><span class="lines">@@ -2853,7 +2853,7 @@
</span><span class="cx">         switch_speech_flag_t flags = SWITCH_SPEECH_FLAG_NONE;
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="cx">
</span><del>-        if (member == NULL || switch_strlen_zero(text))
</del><ins>+        if (member == NULL || zstr(text))
</ins><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">
</span><span class="cx">         switch_assert(conference != NULL);
</span><span class="lines">@@ -2935,7 +2935,7 @@
</span><span class="cx">
</span><span class="cx">         switch_assert(conference != NULL);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(text)) {
</del><ins>+        if (zstr(text)) {
</ins><span class="cx">                 return SWITCH_STATUS_GENERR;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -3123,7 +3123,7 @@
</span><span class="cx">                 return SWITCH_STATUS_GENERR;
</span><span class="cx">
</span><span class="cx">         switch_clear_flag_locked(member, MFLAG_CAN_SPEAK);
</span><del>-        if (!switch_strlen_zero(member->conference->muted_sound)) {
</del><ins>+        if (!zstr(member->conference->muted_sound)) {
</ins><span class="cx">                 conference_member_play_file(member, member->conference->muted_sound, 0);
</span><span class="cx">         } else {
</span><span class="cx">                 char msg[512];
</span><span class="lines">@@ -3155,7 +3155,7 @@
</span><span class="cx">         if (stream != NULL) {
</span><span class="cx">                 stream->write_function(stream, "OK unmute %u\n", member->id);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(member->conference->unmuted_sound)) {
</del><ins>+        if (!zstr(member->conference->unmuted_sound)) {
</ins><span class="cx">                 conference_member_play_file(member, member->conference->unmuted_sound, 0);
</span><span class="cx">         } else {
</span><span class="cx">                 char msg[512];
</span><span class="lines">@@ -3250,7 +3250,7 @@
</span><span class="cx">                 return SWITCH_STATUS_GENERR;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(dtmf)) {
</del><ins>+        if (zstr(dtmf)) {
</ins><span class="cx">                 stream->write_function(stream, "Invalid input!\n");
</span><span class="cx">                 return SWITCH_STATUS_GENERR;
</span><span class="cx">         }
</span><span class="lines">@@ -3620,7 +3620,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_event_t *event;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(text)) {
</del><ins>+        if (zstr(text)) {
</ins><span class="cx">                 stream->write_function(stream, "(say) Error! No text.\n");
</span><span class="cx">                 return SWITCH_STATUS_GENERR;
</span><span class="cx">         }
</span><span class="lines">@@ -3650,7 +3650,7 @@
</span><span class="cx">         conference_member_t *member;
</span><span class="cx">         switch_event_t *event;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(text)) {
</del><ins>+        if (zstr(text)) {
</ins><span class="cx">                 stream->write_function(stream, "(saymember) No Text!\n");
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -3667,7 +3667,7 @@
</span><span class="cx">
</span><span class="cx">         id = atoi(workspace);
</span><span class="cx">
</span><del>-        if (!id || switch_strlen_zero(text)) {
</del><ins>+        if (!id || zstr(text)) {
</ins><span class="cx">                 stream->write_function(stream, "(saymember) No Text!\n");
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -3910,7 +3910,7 @@
</span><span class="cx">         switch_assert(conference != NULL);
</span><span class="cx">         switch_assert(stream != NULL);
</span><span class="cx">
</span><del>-        if (argc > 3 && !switch_strlen_zero(argv[2])) {
</del><ins>+        if (argc > 3 && !zstr(argv[2])) {
</ins><span class="cx">                 int x;
</span><span class="cx">
</span><span class="cx">                 conf_name = strdup(argv[2]);
</span><span class="lines">@@ -4274,7 +4274,7 @@
</span><span class="cx">                                         const char *modified_cmdline = cmdline;
</span><span class="cx">                                         const char *cmd = conf_api_sub_commands[i].pname;
</span><span class="cx">
</span><del>-                                        if (!switch_strlen_zero(modified_cmdline) && (start_text = strstr(modified_cmdline, cmd))) {
</del><ins>+                                        if (!zstr(modified_cmdline) && (start_text = strstr(modified_cmdline, cmd))) {
</ins><span class="cx">                                                 modified_cmdline = start_text + strlen(cmd);
</span><span class="cx">                                                 while (modified_cmdline && (*modified_cmdline == ' ' || *modified_cmdline == '\t')) {
</span><span class="cx">                                                         modified_cmdline++;
</span><span class="lines">@@ -4421,11 +4421,11 @@
</span><span class="cx">                 caller_channel = switch_core_session_get_channel(session);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cid_name)) {
</del><ins>+        if (zstr(cid_name)) {
</ins><span class="cx">                 cid_name = conference->caller_id_name;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cid_num)) {
</del><ins>+        if (zstr(cid_num)) {
</ins><span class="cx">                 cid_num = conference->caller_id_number;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -4810,7 +4810,7 @@
</span><span class="cx">
</span><span class="cx">         call_list = switch_channel_get_private(channel, "_conference_autocall_list_");
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 call_list = NULL;
</span><span class="cx">         } else {
</span><span class="cx">                 np = switch_core_session_alloc(session, sizeof(*np));
</span><span class="lines">@@ -4964,7 +4964,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_CRIT, "Invalid arguments\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -5121,11 +5121,11 @@
</span><span class="cx">                         switch_channel_set_variable(channel, "conference_name", conference->name);
</span><span class="cx">
</span><span class="cx">                         /* Set MOH from variable if not set */
</span><del>-                        if(switch_strlen_zero(conference->moh_sound)) {
</del><ins>+                        if(zstr(conference->moh_sound)) {
</ins><span class="cx">                                 conference->moh_sound = switch_core_strdup(conference->pool, switch_channel_get_variable(channel, "conference_moh_sound"));
</span><span class="cx">                         }
</span><span class="cx">                         /* Set perpetual-sound from variable if not set */
</span><del>-                        if(switch_strlen_zero(conference->perpetual_sound)) {
</del><ins>+                        if(zstr(conference->perpetual_sound)) {
</ins><span class="cx">                                 conference->perpetual_sound = switch_core_strdup(conference->pool, switch_channel_get_variable(channel, "conference_perpetual_sound"));
</span><span class="cx">                         }
</span><span class="cx">                         
</span><span class="lines">@@ -5155,7 +5155,7 @@
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">                 /* if this is not an outbound call, deal with conference pins */
</span><del>-                if (enforce_security && !switch_strlen_zero(dpin)) {
</del><ins>+                if (enforce_security && !zstr(dpin)) {
</ins><span class="cx">                         char pin_buf[80] = "";
</span><span class="cx">                         int pin_retries = 3;        /* XXX - this should be configurable - i'm too lazy to do it right now... */
</span><span class="cx">                         int pin_valid = 0;
</span><span class="lines">@@ -5259,7 +5259,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         /* if we're using "bridge:" make an outbound call and bridge it in */
</span><del>-        if (!switch_strlen_zero(bridgeto) && strcasecmp(bridgeto, "none")) {
</del><ins>+        if (!zstr(bridgeto) && strcasecmp(bridgeto, "none")) {
</ins><span class="cx">                 switch_call_cause_t cause;
</span><span class="cx">                 if (conference_outcall(conference, NULL, session, bridgeto, 60, NULL, NULL, NULL, &cause) != SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                         goto done;
</span><span class="lines">@@ -5512,7 +5512,7 @@
</span><span class="cx">         switch_assert(conference != NULL);
</span><span class="cx">
</span><span class="cx">         for (i = 0, status = SWITCH_STATUS_SUCCESS; status == SWITCH_STATUS_SUCCESS && i < CCFNTBL_QTY; i++) {
</span><del>-                if (!switch_strlen_zero(ccfntbl[i].digits)) {
</del><ins>+                if (!zstr(ccfntbl[i].digits)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG,
</span><span class="cx">                                                          "Installing default caller control action '%s' bound to '%s'.\n", ccfntbl[i].key, ccfntbl[i].digits);
</span><span class="cx">                         action = (caller_control_action_t *) switch_core_alloc(conference->pool, sizeof(caller_control_action_t));
</span><span class="lines">@@ -5548,7 +5548,7 @@
</span><span class="cx">                 char *val = (char *) switch_xml_attr(xml_kvp, "digits");
</span><span class="cx">                 char *data = (char *) switch_xml_attr_soft(xml_kvp, "data");
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(key) && !switch_strlen_zero(val)) {
</del><ins>+                if (!zstr(key) && !zstr(val)) {
</ins><span class="cx">                         uint32_t i;
</span><span class="cx">
</span><span class="cx">                         /* scan through all of the valid actions, and if found, */
</span><span class="lines">@@ -5640,7 +5640,7 @@
</span><span class="cx">         char *auto_record = NULL;
</span><span class="cx">
</span><span class="cx">         /* Validate the conference name */
</span><del>-        if (switch_strlen_zero(name)) {
</del><ins>+        if (zstr(name)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Invalid Record! no name.\n");
</span><span class="cx">                 return NULL;
</span><span class="cx">         }
</span><span class="lines">@@ -5665,14 +5665,14 @@
</span><span class="cx">                         var = buf;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!strcasecmp(var, "rate") && !switch_strlen_zero(val)) {
</del><ins>+                if (!strcasecmp(var, "rate") && !zstr(val)) {
</ins><span class="cx">                         uint32_t tmp = atoi(val);
</span><span class="cx">                         if (tmp == 8000 || tmp == 16000 || tmp == 32000 || tmp == 48000) {
</span><span class="cx">                                 rate = tmp;
</span><span class="cx">                         }
</span><del>-                } else if (!strcasecmp(var, "domain") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "domain") && !zstr(val)) {
</ins><span class="cx">                         domain = val;
</span><del>-                } else if (!strcasecmp(var, "interval") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "interval") && !zstr(val)) {
</ins><span class="cx">                         uint32_t tmp = atoi(val);
</span><span class="cx">                         if (SWITCH_ACCEPTABLE_INTERVAL(tmp)) {
</span><span class="cx">                                 interval = tmp;
</span><span class="lines">@@ -5680,59 +5680,59 @@
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING,
</span><span class="cx">                                                                  "Interval must be multipe of 10 and less than %d, Using default of 20\n", SWITCH_MAX_INTERVAL);
</span><span class="cx">                         }
</span><del>-                } else if (!strcasecmp(var, "timer-name") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "timer-name") && !zstr(val)) {
</ins><span class="cx">                         timer_name = val;
</span><del>-                } else if (!strcasecmp(var, "tts-engine") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "tts-engine") && !zstr(val)) {
</ins><span class="cx">                         tts_engine = val;
</span><del>-                } else if (!strcasecmp(var, "tts-voice") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "tts-voice") && !zstr(val)) {
</ins><span class="cx">                         tts_voice = val;
</span><del>-                } else if (!strcasecmp(var, "enter-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "enter-sound") && !zstr(val)) {
</ins><span class="cx">                         enter_sound = val;
</span><del>-                } else if (!strcasecmp(var, "exit-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "exit-sound") && !zstr(val)) {
</ins><span class="cx">                         exit_sound = val;
</span><del>-                } else if (!strcasecmp(var, "alone-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "alone-sound") && !zstr(val)) {
</ins><span class="cx">                         alone_sound = val;
</span><del>-                } else if (!strcasecmp(var, "perpetual-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "perpetual-sound") && !zstr(val)) {
</ins><span class="cx">                         perpetual_sound = val;
</span><del>-                } else if (!strcasecmp(var, "moh-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "moh-sound") && !zstr(val)) {
</ins><span class="cx">                         moh_sound = val;
</span><del>-                } else if (!strcasecmp(var, "ack-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "ack-sound") && !zstr(val)) {
</ins><span class="cx">                         ack_sound = val;
</span><del>-                } else if (!strcasecmp(var, "nack-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "nack-sound") && !zstr(val)) {
</ins><span class="cx">                         nack_sound = val;
</span><del>-                } else if (!strcasecmp(var, "muted-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "muted-sound") && !zstr(val)) {
</ins><span class="cx">                         muted_sound = val;
</span><del>-                } else if (!strcasecmp(var, "mute-detect-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "mute-detect-sound") && !zstr(val)) {
</ins><span class="cx">                         mute_detect_sound = val;
</span><del>-                } else if (!strcasecmp(var, "unmuted-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "unmuted-sound") && !zstr(val)) {
</ins><span class="cx">                         unmuted_sound = val;
</span><del>-                } else if (!strcasecmp(var, "locked-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "locked-sound") && !zstr(val)) {
</ins><span class="cx">                         locked_sound = val;
</span><del>-                } else if (!strcasecmp(var, "is-locked-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "is-locked-sound") && !zstr(val)) {
</ins><span class="cx">                         is_locked_sound = val;
</span><del>-                } else if (!strcasecmp(var, "is-unlocked-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "is-unlocked-sound") && !zstr(val)) {
</ins><span class="cx">                         is_unlocked_sound = val;
</span><del>-                } else if (!strcasecmp(var, "member-flags") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "member-flags") && !zstr(val)) {
</ins><span class="cx">                         member_flags = val;
</span><del>-                } else if (!strcasecmp(var, "conference-flags") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "conference-flags") && !zstr(val)) {
</ins><span class="cx">                         conference_flags = val;
</span><del>-                } else if (!strcasecmp(var, "kicked-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "kicked-sound") && !zstr(val)) {
</ins><span class="cx">                         kicked_sound = val;
</span><del>-                } else if (!strcasecmp(var, "pin") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "pin") && !zstr(val)) {
</ins><span class="cx">                         pin = val;
</span><del>-                } else if (!strcasecmp(var, "pin-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "pin-sound") && !zstr(val)) {
</ins><span class="cx">                         pin_sound = val;
</span><del>-                } else if (!strcasecmp(var, "bad-pin-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "bad-pin-sound") && !zstr(val)) {
</ins><span class="cx">                         bad_pin_sound = val;
</span><del>-                } else if (!strcasecmp(var, "energy-level") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "energy-level") && !zstr(val)) {
</ins><span class="cx">                         energy_level = val;
</span><del>-                } else if (!strcasecmp(var, "caller-id-name") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "caller-id-name") && !zstr(val)) {
</ins><span class="cx">                         caller_id_name = val;
</span><del>-                } else if (!strcasecmp(var, "caller-id-number") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "caller-id-number") && !zstr(val)) {
</ins><span class="cx">                         caller_id_number = val;
</span><del>-                } else if (!strcasecmp(var, "caller-controls") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "caller-controls") && !zstr(val)) {
</ins><span class="cx">                         caller_controls = val;
</span><del>-                } else if (!strcasecmp(var, "comfort-noise") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "comfort-noise") && !zstr(val)) {
</ins><span class="cx">                         int tmp;
</span><span class="cx">                         tmp = atoi(val);
</span><span class="cx">                         if (tmp > 1 && tmp < 10000) {
</span><span class="lines">@@ -5740,9 +5740,9 @@
</span><span class="cx">                         } else if (switch_true(val)) {
</span><span class="cx">                                 comfort_noise_level = 1400;
</span><span class="cx">                         }
</span><del>-                } else if (!strcasecmp(var, "sound-prefix") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "sound-prefix") && !zstr(val)) {
</ins><span class="cx">                         sound_prefix = val;
</span><del>-                } else if (!strcasecmp(var, "max-members") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "max-members") && !zstr(val)) {
</ins><span class="cx">                         errno = 0;                        /* sanity first */
</span><span class="cx">                         max_members = strtol(val, NULL, 0);        /* base 0 lets 0x... for hex 0... for octal and base 10 otherwise through */
</span><span class="cx">                         if (errno == ERANGE || errno == EINVAL || max_members < 0 || max_members == 1) {
</span><span class="lines">@@ -5752,20 +5752,20 @@
</span><span class="cx">                                 max_members = 0;        /* set to 0 to disable max counts */
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "max-members %s is invalid, not setting a limit\n", val);
</span><span class="cx">                         }
</span><del>-                } else if (!strcasecmp(var, "max-members-sound") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "max-members-sound") && !zstr(val)) {
</ins><span class="cx">                         maxmember_sound = val;
</span><del>-                } else if (!strcasecmp(var, "announce-count") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "announce-count") && !zstr(val)) {
</ins><span class="cx">                         errno = 0;                        /* safety first */
</span><span class="cx">                         announce_count = strtol(val, NULL, 0);
</span><span class="cx">                         if (errno == ERANGE || errno == EINVAL) {
</span><span class="cx">                                 announce_count = 0;
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "announce-count is invalid, not anouncing member counts\n");
</span><span class="cx">                         }
</span><del>-                } else if (!strcasecmp(var, "suppress-events") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "suppress-events") && !zstr(val)) {
</ins><span class="cx">                         suppress_events = val;
</span><del>-                } else if (!strcasecmp(var, "verbose-events") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "verbose-events") && !zstr(val)) {
</ins><span class="cx">                         verbose_events = val;
</span><del>-                } else if (!strcasecmp(var, "auto-record") && !switch_strlen_zero(val)) {
</del><ins>+                } else if (!strcasecmp(var, "auto-record") && !zstr(val)) {
</ins><span class="cx">                         auto_record = val;
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="lines">@@ -5773,17 +5773,17 @@
</span><span class="cx">         /* Set defaults and various paramaters */
</span><span class="cx">
</span><span class="cx">         /* Timer module to use */
</span><del>-        if (switch_strlen_zero(timer_name)) {
</del><ins>+        if (zstr(timer_name)) {
</ins><span class="cx">                 timer_name = "soft";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         /* Caller ID Name */
</span><del>-        if (switch_strlen_zero(caller_id_name)) {
</del><ins>+        if (zstr(caller_id_name)) {
</ins><span class="cx">                 caller_id_name = (char *) global_app_name;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         /* Caller ID Number */
</span><del>-        if (switch_strlen_zero(caller_id_number)) {
</del><ins>+        if (zstr(caller_id_number)) {
</ins><span class="cx">                 caller_id_number = "0000000000";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -5823,13 +5823,13 @@
</span><span class="cx">         conference->caller_id_number = switch_core_strdup(conference->pool, caller_id_number);
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(perpetual_sound)) {
</del><ins>+        if (!zstr(perpetual_sound)) {
</ins><span class="cx">                 conference->perpetual_sound = switch_core_strdup(conference->pool, perpetual_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         conference->mflags = MFLAG_CAN_SPEAK | MFLAG_CAN_HEAR;
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(moh_sound) && switch_is_moh(moh_sound)) {
</del><ins>+        if (!zstr(moh_sound) && switch_is_moh(moh_sound)) {
</ins><span class="cx">                 conference->moh_sound = switch_core_strdup(conference->pool, moh_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -5845,75 +5845,75 @@
</span><span class="cx">                 conference->sound_prefix = switch_core_strdup(conference->pool, sound_prefix);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(enter_sound)) {
</del><ins>+        if (!zstr(enter_sound)) {
</ins><span class="cx">                 conference->enter_sound = switch_core_strdup(conference->pool, enter_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(exit_sound)) {
</del><ins>+        if (!zstr(exit_sound)) {
</ins><span class="cx">                 conference->exit_sound = switch_core_strdup(conference->pool, exit_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(ack_sound)) {
</del><ins>+        if (!zstr(ack_sound)) {
</ins><span class="cx">                 conference->ack_sound = switch_core_strdup(conference->pool, ack_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(nack_sound)) {
</del><ins>+        if (!zstr(nack_sound)) {
</ins><span class="cx">                 conference->nack_sound = switch_core_strdup(conference->pool, nack_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(muted_sound)) {
</del><ins>+        if (!zstr(muted_sound)) {
</ins><span class="cx">                 conference->muted_sound = switch_core_strdup(conference->pool, muted_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(mute_detect_sound)) {
-                if (!switch_strlen_zero(muted_sound)) {
</del><ins>+        if (zstr(mute_detect_sound)) {
+                if (!zstr(muted_sound)) {
</ins><span class="cx">                         conference->mute_detect_sound = switch_core_strdup(conference->pool, muted_sound);
</span><span class="cx">                 }
</span><span class="cx">         } else {
</span><span class="cx">                 conference->mute_detect_sound = switch_core_strdup(conference->pool, mute_detect_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(unmuted_sound)) {
</del><ins>+        if (!zstr(unmuted_sound)) {
</ins><span class="cx">                 conference->unmuted_sound = switch_core_strdup(conference->pool, unmuted_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(kicked_sound)) {
</del><ins>+        if (!zstr(kicked_sound)) {
</ins><span class="cx">                 conference->kicked_sound = switch_core_strdup(conference->pool, kicked_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(pin_sound)) {
</del><ins>+        if (!zstr(pin_sound)) {
</ins><span class="cx">                 conference->pin_sound = switch_core_strdup(conference->pool, pin_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(bad_pin_sound)) {
</del><ins>+        if (!zstr(bad_pin_sound)) {
</ins><span class="cx">                 conference->bad_pin_sound = switch_core_strdup(conference->pool, bad_pin_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(pin)) {
</del><ins>+        if (!zstr(pin)) {
</ins><span class="cx">                 conference->pin = switch_core_strdup(conference->pool, pin);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(alone_sound)) {
</del><ins>+        if (!zstr(alone_sound)) {
</ins><span class="cx">                 conference->alone_sound = switch_core_strdup(conference->pool, alone_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(locked_sound)) {
</del><ins>+        if (!zstr(locked_sound)) {
</ins><span class="cx">                 conference->locked_sound = switch_core_strdup(conference->pool, locked_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(is_locked_sound)) {
</del><ins>+        if (!zstr(is_locked_sound)) {
</ins><span class="cx">                 conference->is_locked_sound = switch_core_strdup(conference->pool, is_locked_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(is_unlocked_sound)) {
</del><ins>+        if (!zstr(is_unlocked_sound)) {
</ins><span class="cx">                 conference->is_unlocked_sound = switch_core_strdup(conference->pool, is_unlocked_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(energy_level)) {
</del><ins>+        if (!zstr(energy_level)) {
</ins><span class="cx">                 conference->energy_level = atoi(energy_level);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(maxmember_sound)) {
</del><ins>+        if (!zstr(maxmember_sound)) {
</ins><span class="cx">                 conference->maxmember_sound = switch_core_strdup(conference->pool, maxmember_sound);
</span><span class="cx">         }
</span><span class="cx">         /* its going to be 0 by default, set to a value otherwise so this should be safe */
</span><span class="lines">@@ -5931,15 +5931,15 @@
</span><span class="cx">         conference->dtmf_parser = NULL;
</span><span class="cx">
</span><span class="cx">         conference->eflags = 0xFFFFFFFF;
</span><del>-        if (!switch_strlen_zero(suppress_events)) {
</del><ins>+        if (!zstr(suppress_events)) {
</ins><span class="cx">                 clear_eflags(suppress_events, &conference->eflags);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(auto_record)) {
</del><ins>+        if (!zstr(auto_record)) {
</ins><span class="cx">                 conference->auto_record = switch_core_strdup(conference->pool, auto_record);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(verbose_events) && switch_true(verbose_events)) {
</del><ins>+        if (!zstr(verbose_events) && switch_true(verbose_events)) {
</ins><span class="cx">                 conference->verbose_events = 1;
</span><span class="cx">         }
</span><span class="cx">         
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_curlmod_curlc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_curl/mod_curl.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_curl/mod_curl.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_curl/mod_curl.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -151,7 +151,7 @@
</span><span class="cx">         curl_easy_cleanup(curl_handle);
</span><span class="cx">         
</span><span class="cx">         if (        http_data->stream.data &&
</span><del>-                        !switch_strlen_zero((char *)http_data->stream.data) &&
</del><ins>+                        !zstr((char *)http_data->stream.data) &&
</ins><span class="cx">                         strcmp(" ", http_data->stream.data) ) {
</span><span class="cx">                 
</span><span class="cx">                 http_data->http_response = switch_core_strdup(pool, http_data->stream.data);
</span><span class="lines">@@ -185,7 +185,7 @@
</span><span class="cx">                         *data = '\0';
</span><span class="cx">                 }
</span><span class="cx">                 
</span><del>-                if switch_strlen_zero(header->data) {
</del><ins>+                if zstr(header->data) {
</ins><span class="cx">                         header = header->next;
</span><span class="cx">                         continue;
</span><span class="cx">                 }
</span><span class="lines">@@ -336,7 +336,7 @@
</span><span class="cx">
</span><span class="cx">         switch_memory_pool_t *pool = NULL;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 switch_goto_status(SWITCH_STATUS_SUCCESS, usage);
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_directorymod_directoryc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_directory/mod_directory.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_directory/mod_directory.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_directory/mod_directory.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -542,7 +542,7 @@
</span><span class="cx">                                         } else {
</span><span class="cx">                                                 fullName = caller_name;
</span><span class="cx">                                         }
</span><del>-                                        if (switch_strlen_zero(fullName)) {
</del><ins>+                                        if (zstr(fullName)) {
</ins><span class="cx">                                                 continue;
</span><span class="cx">                                         }
</span><span class="cx">                                         firstName = switch_core_session_strdup(session, fullName);
</span><span class="lines">@@ -649,29 +649,29 @@
</span><span class="cx">                 switch_safe_free(stream.data);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero_buf(buf)) {
</del><ins>+        if (zstr_buf(buf)) {
</ins><span class="cx">                 switch_snprintf(macro, sizeof(macro), "phrase:%s:%d", DIR_RESULT_ITEM, cbt->want+1);
</span><span class="cx">                 switch_ivr_read(session, 0, 1, macro, NULL, buf, sizeof(buf), 1, profile->terminator_key);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero_buf(recorded_name) && switch_strlen_zero_buf(buf)) {
</del><ins>+        if (!zstr_buf(recorded_name) && zstr_buf(buf)) {
</ins><span class="cx"> switch_ivr_read(session, 0, 1, recorded_name, NULL, buf, sizeof(buf), 1, profile->terminator_key);
</span><span class="cx">
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero_buf(recorded_name) && switch_strlen_zero_buf(buf)) {
</del><ins>+        if (zstr_buf(recorded_name) && zstr_buf(buf)) {
</ins><span class="cx">                 switch_snprintf(macro, sizeof(macro), "phrase:%s:%s", DIR_RESULT_SAY_NAME, cbt->fullname);
</span><span class="cx">                 switch_ivr_read(session, 0, 1, macro, NULL, buf, sizeof(buf), 1, profile->terminator_key);
</span><span class="cx">         }
</span><del>-        if (cbt->exten_visible && switch_strlen_zero_buf(buf)) {
</del><ins>+        if (cbt->exten_visible && zstr_buf(buf)) {
</ins><span class="cx">                 switch_snprintf(macro, sizeof(macro), "phrase:%s:%s", DIR_RESULT_AT, cbt->extension);
</span><span class="cx">                 switch_ivr_read(session, 0, 1, macro, NULL, buf, sizeof(buf), 1, profile->terminator_key);
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero_buf(buf)) {
</del><ins>+        if (zstr_buf(buf)) {
</ins><span class="cx">                 switch_snprintf(macro, sizeof(macro), "phrase:%s:%c,%c,%c,%c", DIR_RESULT_MENU, *profile->select_name_key, *profile->next_key, *profile->prev_key, *profile->new_search_key);
</span><span class="cx">                 switch_ivr_read(session, 0, 1, macro, NULL, buf, sizeof(buf), profile->digit_timeout, profile->terminator_key);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero_buf(buf)) {
</del><ins>+        if (!zstr_buf(buf)) {
</ins><span class="cx">                 if (buf[0] == *profile->select_name_key) {
</span><span class="cx">                         switch_copy_string(cbt->transfer_to, cbt->extension, 255);
</span><span class="cx">                 }
</span><span class="lines">@@ -781,7 +781,7 @@
</span><span class="cx">                 listing_cbt.move = ENTRY_MOVE_NEXT;
</span><span class="cx">                 directory_execute_sql_callback(profile->mutex, sql, listing_callback, &listing_cbt);
</span><span class="cx">                 status = listen_entry(session, profile, &listing_cbt);
</span><del>-                if (!switch_strlen_zero(listing_cbt.transfer_to)) {
</del><ins>+                if (!zstr(listing_cbt.transfer_to)) {
</ins><span class="cx">                         switch_copy_string(params->transfer_to, listing_cbt.transfer_to, 255);
</span><span class="cx">                         break;
</span><span class="cx">                 }
</span><span class="lines">@@ -833,7 +833,7 @@
</span><span class="cx">         int attempts = 3;
</span><span class="cx">         char macro[255];
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Missing profile name\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -871,7 +871,7 @@
</span><span class="cx">                 s_param.try_again = 0;
</span><span class="cx">                 gather_name_digit(session, profile, &s_param);
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(s_param.digits)) {
</del><ins>+                if (zstr(s_param.digits)) {
</ins><span class="cx">                         s_param.try_again = 1;
</span><span class="cx">                         continue;
</span><span class="cx">                 }
</span><span class="lines">@@ -886,7 +886,7 @@
</span><span class="cx">                 navigate_entrys(session, profile, &s_param);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(s_param.transfer_to)) {
</del><ins>+        if (!zstr(s_param.transfer_to)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Directory transfering call to : %s\n", s_param.transfer_to);
</span><span class="cx">                 switch_ivr_session_transfer(session, s_param.transfer_to, "XML", domain_name);
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_dptoolsmod_dptoolsc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -55,11 +55,11 @@
</span><span class="cx">                 abort();
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(target)) {
</del><ins>+        if (zstr(target)) {
</ins><span class="cx">                 target = caller_profile->destination_number;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(target) && (lbuf = switch_core_session_strdup(session, target))
</del><ins>+        if (!zstr(target) && (lbuf = switch_core_session_strdup(session, target))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ',', argv, (sizeof(argv) / sizeof(argv[0]))))) {
</span><span class="cx">         } else {
</span><span class="cx">                 return NULL;
</span><span class="lines">@@ -91,7 +91,7 @@
</span><span class="cx">         int argc;
</span><span class="cx">         char *lbuf = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (lbuf = switch_core_session_strdup(session, data))
</del><ins>+        if (!zstr(data) && (lbuf = switch_core_session_strdup(session, data))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ' ', argv, (sizeof(argv) / sizeof(argv[0]))))) {
</span><span class="cx">                 if (!strcasecmp(argv[0], "grammar") && argc >= 1) {
</span><span class="cx">                         switch_ivr_detect_speech_load_grammar(session, argv[1], argv[2]);
</span><span class="lines">@@ -154,7 +154,7 @@
</span><span class="cx">         int argc;
</span><span class="cx">         char *lbuf = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (lbuf = switch_core_session_strdup(session, data))
</del><ins>+        if (!zstr(data) && (lbuf = switch_core_session_strdup(session, data))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ' ', argv, (sizeof(argv) / sizeof(argv[0]))))) {
</span><span class="cx">                 switch_core_session_execute_exten(session, argv[0], argv[1], argv[2]);
</span><span class="cx">         } else {
</span><span class="lines">@@ -176,7 +176,7 @@
</span><span class="cx">         int argc;
</span><span class="cx">         char *lbuf = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (lbuf = switch_core_session_strdup(session, data))
</del><ins>+        if (!zstr(data) && (lbuf = switch_core_session_strdup(session, data))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) >= 1) {
</span><span class="cx">                 switch_ivr_soft_hold(session, argv[0], argv[1], argv[2]);
</span><span class="cx">         } else {
</span><span class="lines">@@ -205,7 +205,7 @@
</span><span class="cx">         int argc;
</span><span class="cx">         char *lbuf = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (lbuf = switch_core_session_strdup(session, data))
</del><ins>+        if (!zstr(data) && (lbuf = switch_core_session_strdup(session, data))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) == 4) {
</span><span class="cx">                 int kval = atoi(argv[0]);
</span><span class="cx">                 switch_bind_flag_t bind_flags = 0;
</span><span class="lines">@@ -283,7 +283,7 @@
</span><span class="cx">         char *uuid;
</span><span class="cx">         switch_bool_t bleg = SWITCH_FALSE;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (!zstr(data) && (mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 if ((argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) >= 1) {
</span><span class="cx">                         if (!strcasecmp(argv[0], "-bleg")) {
</span><span class="cx">                                 if (argv[1]) {
</span><span class="lines">@@ -327,7 +327,7 @@
</span><span class="cx"> #define eavesdrop_SYNTAX "[all | <uuid>]"
</span><span class="cx"> SWITCH_STANDARD_APP(eavesdrop_function)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Usage: %s\n", eavesdrop_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="lines">@@ -401,7 +401,7 @@
</span><span class="cx"> #define threeway_SYNTAX "<uuid>"
</span><span class="cx"> SWITCH_STANDARD_APP(three_way_function)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Usage: %s\n", threeway_SYNTAX);
</span><span class="cx">         } else {
</span><span class="cx">                 switch_ivr_eavesdrop_session(session, data, NULL, ED_MUX_READ | ED_MUX_WRITE);
</span><span class="lines">@@ -458,7 +458,7 @@
</span><span class="cx">         char *mydata;
</span><span class="cx">         switch_call_cause_t cause = SWITCH_CAUSE_CALL_REJECTED;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (!zstr(data) && (mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 if ((argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) > 1) {
</span><span class="cx">                         if (!switch_check_network_list_ip(argv[0], argv[1])) {
</span><span class="cx">                                 switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="lines">@@ -486,7 +486,7 @@
</span><span class="cx">         int bleg = 0, both = 0;
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (!zstr(data) && (mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 if ((argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) >= 1) {
</span><span class="cx">                         bleg = !strcasecmp(argv[0], "-bleg");
</span><span class="cx">                         both = !strcasecmp(argv[0], "-both");
</span><span class="lines">@@ -521,7 +521,7 @@
</span><span class="cx">         char *argv[4] = { 0 };
</span><span class="cx">         char *mydata;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (!zstr(data) && (mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 if ((argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) >= 2) {
</span><span class="cx">                         time_t when;
</span><span class="cx">
</span><span class="lines">@@ -544,7 +544,7 @@
</span><span class="cx">         char *argv[5] = { 0 };
</span><span class="cx">         char *mydata;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (!zstr(data) && (mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 if ((argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) >= 1) {
</span><span class="cx">                         time_t when;
</span><span class="cx">                         switch_call_cause_t cause = SWITCH_CAUSE_ALLOTTED_TIMEOUT;
</span><span class="lines">@@ -577,7 +577,7 @@
</span><span class="cx">         char *argv[6] = { 0 };
</span><span class="cx">         char *mydata;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (!zstr(data) && (mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 if ((argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) >= 2) {
</span><span class="cx">                         time_t when;
</span><span class="cx">                         switch_media_flag_t flags = SMF_NONE;
</span><span class="lines">@@ -611,7 +611,7 @@
</span><span class="cx"> {
</span><span class="cx">         uint32_t len = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 len = 1000;
</span><span class="cx">         } else {
</span><span class="cx">                 len = atoi(data);
</span><span class="lines">@@ -630,7 +630,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_call_cause_t cause = SWITCH_CAUSE_NORMAL_CLEARING;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 cause = switch_channel_str2cause(data);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -640,7 +640,7 @@
</span><span class="cx"> SWITCH_STANDARD_APP(set_name_function)
</span><span class="cx"> {
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 switch_channel_set_name(switch_core_session_get_channel(session), (char *) data);
</span><span class="cx">         }
</span><span class="cx"> }
</span><span class="lines">@@ -660,7 +660,7 @@
</span><span class="cx">         char *mydata = NULL;
</span><span class="cx">         switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data) || !(mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (zstr(data) || !(mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "INVALID ARGS!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -729,7 +729,7 @@
</span><span class="cx"> {
</span><span class="cx">         char *var, *val = NULL;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No variable name specified.\n");
</span><span class="cx">         } else {
</span><span class="cx">                 switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="lines">@@ -740,7 +740,7 @@
</span><span class="cx">
</span><span class="cx">                 if (val) {
</span><span class="cx">                         *val++ = '\0';
</span><del>-                        if (switch_strlen_zero(val)) {
</del><ins>+                        if (zstr(val)) {
</ins><span class="cx">                                 val = NULL;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="lines">@@ -762,7 +762,7 @@
</span><span class="cx"> {
</span><span class="cx">         char *var, *val = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No variable name specified.\n");
</span><span class="cx">         } else {
</span><span class="cx">                 var = strdup(data);
</span><span class="lines">@@ -771,7 +771,7 @@
</span><span class="cx">
</span><span class="cx">                 if (val) {
</span><span class="cx">                         *val++ = '\0';
</span><del>-                        if (switch_strlen_zero(val)) {
</del><ins>+                        if (zstr(val)) {
</ins><span class="cx">                                 val = NULL;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="lines">@@ -786,7 +786,7 @@
</span><span class="cx"> {
</span><span class="cx">         char *name, *val = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No variable name specified.\n");
</span><span class="cx">         } else {
</span><span class="cx">                 name = switch_core_session_strdup(session, data);
</span><span class="lines">@@ -794,7 +794,7 @@
</span><span class="cx">
</span><span class="cx">                 if (val) {
</span><span class="cx">                         *val++ = '\0';
</span><del>-                        if (switch_strlen_zero(val)) {
</del><ins>+                        if (zstr(val)) {
</ins><span class="cx">                                 val = NULL;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="lines">@@ -810,7 +810,7 @@
</span><span class="cx">         char *new_exports = NULL, *new_exports_d = NULL, *var, *val = NULL, *var_name = NULL;
</span><span class="cx">         int local = 1;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No variable name specified.\n");
</span><span class="cx">         } else {
</span><span class="cx">                 exports = switch_channel_get_variable(channel, SWITCH_EXPORT_VARS_VARIABLE);
</span><span class="lines">@@ -827,7 +827,7 @@
</span><span class="cx">
</span><span class="cx">                 if (val) {
</span><span class="cx">                         *val++ = '\0';
</span><del>-                        if (switch_strlen_zero(val)) {
</del><ins>+                        if (zstr(val)) {
</ins><span class="cx">                                 val = NULL;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="lines">@@ -853,7 +853,7 @@
</span><span class="cx">
</span><span class="cx"> SWITCH_STANDARD_APP(unset_function)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No variable name specified.\n");
</span><span class="cx">         } else {
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "UNSET [%s]\n", (char *) data);
</span><span class="lines">@@ -889,7 +889,7 @@
</span><span class="cx">         char *buf;
</span><span class="cx">         int level = SWITCH_LOG_INFO;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 level = switch_log_str2level(data);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -916,7 +916,7 @@
</span><span class="cx">         char *lbuf;
</span><span class="cx">
</span><span class="cx">         if (switch_event_create(&event, SWITCH_EVENT_CHANNEL_APPLICATION) == SWITCH_STATUS_SUCCESS) {
</span><del>-                if (!switch_strlen_zero(data) && (lbuf = switch_core_session_strdup(session, data))
</del><ins>+                if (!zstr(data) && (lbuf = switch_core_session_strdup(session, data))
</ins><span class="cx">                         && (argc = switch_separate_string(lbuf, ',', argv, (sizeof(argv) / sizeof(argv[0]))))) {
</span><span class="cx">                         int x = 0;
</span><span class="cx">
</span><span class="lines">@@ -966,7 +966,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_caller_profile_t *caller_profile = switch_channel_get_caller_profile(switch_core_session_get_channel(session));
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No privacy mode specified.\n");
</span><span class="cx">         } else {
</span><span class="cx">                 switch_set_flag(caller_profile, SWITCH_CPF_SCREEN);
</span><span class="lines">@@ -996,7 +996,7 @@
</span><span class="cx">         int argc;
</span><span class="cx">         char *lbuf;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (lbuf = switch_core_session_strdup(session, data))
</del><ins>+        if (!zstr(data) && (lbuf = switch_core_session_strdup(session, data))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, '=', argv, (sizeof(argv) / sizeof(argv[0])))) > 1) {
</span><span class="cx">                 switch_size_t retsize;
</span><span class="cx">                 switch_time_exp_t tm;
</span><span class="lines">@@ -1013,7 +1013,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_time_t out;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 out = switch_micro_time_now();
</span><span class="cx">         } else {
</span><span class="cx">                 out = switch_str_time(cmd);
</span><span class="lines">@@ -1031,14 +1031,14 @@
</span><span class="cx">         char date[80] = "";
</span><span class="cx">         switch_time_t thetime;
</span><span class="cx">         char *p;
</span><del>-        if (!switch_strlen_zero(cmd) && (p = strchr(cmd, '|'))) {
</del><ins>+        if (!zstr(cmd) && (p = strchr(cmd, '|'))) {
</ins><span class="cx">                 thetime = switch_time_make(atoi(cmd), 0);
</span><span class="cx">                 cmd = p + 1;
</span><span class="cx">         } else {
</span><span class="cx">                 thetime = switch_micro_time_now();
</span><span class="cx">         }
</span><span class="cx">         switch_time_exp_lt(&tm, thetime);
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 switch_strftime_nocheck(date, &retsize, sizeof(date), "%Y-%m-%d %T", &tm);
</span><span class="cx">         } else {
</span><span class="cx">                 switch_strftime(date, &retsize, sizeof(date), cmd, &tm);
</span><span class="lines">@@ -1058,7 +1058,7 @@
</span><span class="cx">         switch_event_types_t type = SWITCH_EVENT_PRESENCE_IN;
</span><span class="cx">         int need = 4;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (lbuf = strdup(cmd))
</del><ins>+        if (!zstr(cmd) && (lbuf = strdup(cmd))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) > 0) {
</span><span class="cx">
</span><span class="cx">                 if (!strcasecmp(argv[0], "out")) {
</span><span class="lines">@@ -1111,11 +1111,11 @@
</span><span class="cx">         char *lbuf = NULL, *argv[5];
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (lbuf = strdup(cmd))
</del><ins>+        if (!zstr(cmd) && (lbuf = strdup(cmd))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, '|', argv, (sizeof(argv) / sizeof(argv[0])))) >= 4) {
</span><span class="cx">
</span><span class="cx">                 if (switch_core_chat_send(argv[0], "dp", argv[1], argv[2], "", argv[3],
</span><del>-                                                                 !switch_strlen_zero(argv[4]) ? argv[4] : NULL , "") == SWITCH_STATUS_SUCCESS) {
</del><ins>+                                                                 !zstr(argv[4]) ? argv[4] : NULL , "") == SWITCH_STATUS_SUCCESS) {
</ins><span class="cx">                         stream->write_function(stream, "Sent");
</span><span class="cx">                 } else {
</span><span class="cx">                         stream->write_function(stream, "Error! Message Not Sent");
</span><span class="lines">@@ -1206,7 +1206,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_bool_t do_read = SWITCH_TRUE;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 if (!strcasecmp(data, "write")) {
</span><span class="cx">                         do_read = SWITCH_FALSE;
</span><span class="cx">                 }
</span><span class="lines">@@ -1240,7 +1240,7 @@
</span><span class="cx">         time_t to = 0;
</span><span class="cx">         int hits = 1;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data) || !(mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (zstr(data) || !(mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "INVALID ARGS!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -1362,7 +1362,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No timeout specified.\n");
</span><span class="cx">         } else {
</span><span class="cx">                 uint32_t ms = atoi(data);
</span><span class="lines">@@ -1397,7 +1397,7 @@
</span><span class="cx">         char *mydata = NULL;
</span><span class="cx">         switch_input_args_t args = { 0 };
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data) || !(mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (zstr(data) || !(mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Invalid Params!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -1610,7 +1610,7 @@
</span><span class="cx">         const char *var_name = NULL;
</span><span class="cx">         const char *valid_terminators = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (!zstr(data) && (mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         } else {
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No arguments specified.\n");
</span><span class="lines">@@ -1651,7 +1651,7 @@
</span><span class="cx">                 timeout = 1000;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(valid_terminators)) {
</del><ins>+        if (zstr(valid_terminators)) {
</ins><span class="cx">                 valid_terminators = "#";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1674,7 +1674,7 @@
</span><span class="cx">         const char *valid_terminators = NULL;
</span><span class="cx">         const char *digits_regex = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (!zstr(data) && (mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         } else {
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No arguments specified.\n");
</span><span class="lines">@@ -1727,7 +1727,7 @@
</span><span class="cx">                 timeout = 1000;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(valid_terminators)) {
</del><ins>+        if (zstr(valid_terminators)) {
</ins><span class="cx">                 valid_terminators = "#";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1744,7 +1744,7 @@
</span><span class="cx">         switch_input_args_t args = { 0 };
</span><span class="cx">         switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (lbuf = switch_core_session_strdup(session, data))
</del><ins>+        if (!zstr(data) && (lbuf = switch_core_session_strdup(session, data))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) == 4) {
</span><span class="cx">                 
</span><span class="cx">                 args.input_callback = on_dtmf;
</span><span class="lines">@@ -1766,7 +1766,7 @@
</span><span class="cx">         switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="cx">         switch_status_t status;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (!zstr(data) && (mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 const char *lang;
</span><span class="cx">                 char *macro = mydata;
</span><span class="cx">                 char *mdata = NULL;
</span><span class="lines">@@ -1885,7 +1885,7 @@
</span><span class="cx">         int32_t loops = 0;
</span><span class="cx">         switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data) || !(tone_script = switch_core_session_strdup(session, data))) {
</del><ins>+        if (zstr(data) || !(tone_script = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Invalid Params!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -1915,13 +1915,13 @@
</span><span class="cx">         char *lbuf = NULL;
</span><span class="cx">         char *flags = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (lbuf = switch_core_session_strdup(session, data))
</del><ins>+        if (!zstr(data) && (lbuf = switch_core_session_strdup(session, data))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ' ', argv, (sizeof(argv) / sizeof(argv[0]))))) {
</span><span class="cx">                 path = argv[0];
</span><span class="cx">                 for (x = 1; x < argc; x++) {
</span><span class="cx">                         if (strchr(argv[x], '+')) {
</span><span class="cx">                                 limit = atoi(argv[x]);
</span><del>-                        } else if (!switch_strlen_zero(argv[x])) {
</del><ins>+                        } else if (!zstr(argv[x])) {
</ins><span class="cx">                                 flags = argv[x];
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="lines">@@ -1948,7 +1948,7 @@
</span><span class="cx">         const char *tmp;
</span><span class="cx">         int rate;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (mydata = switch_core_session_strdup(session, data))) {
</del><ins>+        if (!zstr(data) && (mydata = switch_core_session_strdup(session, data))) {
</ins><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         } else {
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No file specified.\n");
</span><span class="lines">@@ -2013,7 +2013,7 @@
</span><span class="cx">         char *path_end;
</span><span class="cx">         uint32_t limit = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2095,7 +2095,7 @@
</span><span class="cx">         char *camp_data = NULL;
</span><span class="cx">         switch_status_t status;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2214,7 +2214,7 @@
</span><span class="cx">                         switch_channel_clear_flag(caller_channel, CF_NOT_READY);
</span><span class="cx">                 }
</span><span class="cx">                 
</span><del>-                if (do_xfer && !switch_strlen_zero(v_campon_fallback_exten)) {
</del><ins>+                if (do_xfer && !zstr(v_campon_fallback_exten)) {
</ins><span class="cx">                         switch_ivr_session_transfer(session,
</span><span class="cx">                                                                                 v_campon_fallback_exten,
</span><span class="cx">                                                                                 switch_channel_get_variable(caller_channel, "campon_fallback_dialplan"),
</span><span class="lines">@@ -2468,7 +2468,7 @@
</span><span class="cx">         char stupid[128] = "";
</span><span class="cx">         const char *skip = NULL, *var = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(outbound_profile->destination_number)) {
</del><ins>+        if (zstr(outbound_profile->destination_number)) {
</ins><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2699,7 +2699,7 @@
</span><span class="cx">         int argc;
</span><span class="cx">         char *lbuf = NULL;
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(data) && (lbuf = switch_core_session_strdup(session, data))
</del><ins>+        if (!zstr(data) && (lbuf = switch_core_session_strdup(session, data))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) >= 3) {
</span><span class="cx">                 thresh = atoi(argv[0]);
</span><span class="cx">                 silence_hits = atoi(argv[1]);
</span><span class="lines">@@ -2776,7 +2776,7 @@
</span><span class="cx">
</span><span class="cx">                 if (proto) {
</span><span class="cx">                         switch_core_chat_send(proto, "api", to, hint && strchr(hint, '/') ? hint : from,
</span><del>-                                                                 !switch_strlen_zero(type) ? type : NULL, (char *) stream.data, NULL, NULL);
</del><ins>+                                                                 !zstr(type) ? type : NULL, (char *) stream.data, NULL, NULL);
</ins><span class="cx">                 }
</span><span class="cx">
</span><span class="cx">                 switch_safe_free(stream.data);
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_easyroutemod_easyroutec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_easyroute/mod_easyroute.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_easyroute/mod_easyroute.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_easyroute/mod_easyroute.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -125,13 +125,13 @@
</span><span class="cx">         }
</span><span class="cx">         
</span><span class="cx"> done:
</span><del>-        if (switch_strlen_zero(globals.db_username)) {
</del><ins>+        if (zstr(globals.db_username)) {
</ins><span class="cx">                 set_global_db_username("root");
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(globals.db_password)) {
</del><ins>+        if (zstr(globals.db_password)) {
</ins><span class="cx">                 set_global_db_password("password");
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(globals.db_dsn)) {
</del><ins>+        if (zstr(globals.db_dsn)) {
</ins><span class="cx">                 set_global_db_dsn("easyroute");
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -208,25 +208,25 @@
</span><span class="cx">                 char tmp_profile[129];
</span><span class="cx">                 char tmp_gateway[129];
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(pdata.limit)) {
</del><ins>+                if (zstr(pdata.limit)) {
</ins><span class="cx">                         switch_set_string(results->limit, "9999" );
</span><span class="cx">                 } else {
</span><span class="cx">                         switch_set_string(results->limit, pdata.limit );
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(pdata.techprofile)){
</del><ins>+                if (zstr(pdata.techprofile)){
</ins><span class="cx">                         switch_set_string(tmp_profile, globals.default_techprofile);
</span><span class="cx">                 } else {
</span><span class="cx">                         switch_set_string(tmp_profile, pdata.techprofile);
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(pdata.gateway)){
</del><ins>+                if (zstr(pdata.gateway)){
</ins><span class="cx">                         switch_set_string(tmp_gateway, globals.default_gateway);
</span><span class="cx">                 } else {
</span><span class="cx">                         switch_set_string(tmp_gateway, pdata.gateway);
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(pdata.translated)){
</del><ins>+                if (zstr(pdata.translated)){
</ins><span class="cx">                         switch_set_string(results->translated, dn);
</span><span class="cx">                 } else {
</span><span class="cx">                         switch_set_string(results->translated, pdata.translated);
</span><span class="lines">@@ -240,13 +240,13 @@
</span><span class="cx">                 }
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "THE ROUTE [%s]\n", results->dialstring);
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(pdata.group)){
</del><ins>+                if (zstr(pdata.group)){
</ins><span class="cx">                         switch_set_string(results->group, "");
</span><span class="cx">                 } else {
</span><span class="cx">                         switch_set_string(results->group, pdata.group);
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(pdata.acctcode)){
</del><ins>+                if (zstr(pdata.acctcode)){
</ins><span class="cx">                         switch_set_string(results->acctcode, "");
</span><span class="cx">                 } else {
</span><span class="cx">                         switch_set_string(results->acctcode, pdata.acctcode);
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_enummod_enumc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_enum/mod_enum.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_enum/mod_enum.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_enum/mod_enum.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -471,7 +471,7 @@
</span><span class="cx">                 root = mroot;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(root)) {
</del><ins>+        if (zstr(root)) {
</ins><span class="cx">                 root = globals.root;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -675,7 +675,7 @@
</span><span class="cx">         char *last_delim = "|";
</span><span class="cx">         int ok = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "%s", "none");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_esfmod_esfc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_esf/mod_esf.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_esf/mod_esf.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_esf/mod_esf.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -83,7 +83,7 @@
</span><span class="cx">
</span><span class="cx"> switch_core_session_get_read_impl(session, &read_impl);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero((char *) data)) {
</del><ins>+        if (!zstr((char *) data)) {
</ins><span class="cx">                 mydata = switch_core_session_strdup(session, data);
</span><span class="cx">                 assert(mydata != NULL);
</span><span class="cx">
</span><span class="lines">@@ -93,20 +93,20 @@
</span><span class="cx">                         mcast_ip = switch_core_session_strdup(session, var);
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[0])) {
</del><ins>+                if (!zstr(argv[0])) {
</ins><span class="cx">                         mcast_ip = argv[0];
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[1])) {
</del><ins>+                if (!zstr(argv[1])) {
</ins><span class="cx">                         mcast_port_str = argv[1];
</span><span class="cx">                         mcast_port = (switch_port_t) atoi(mcast_port_str);
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[2])) {
</del><ins>+                if (!zstr(argv[2])) {
</ins><span class="cx">                         mcast_control_port = (switch_port_t) atoi(argv[2]);
</span><span class="cx">                 }
</span><span class="cx">                 
</span><del>-                if (!switch_strlen_zero(argv[3])) {
</del><ins>+                if (!zstr(argv[3])) {
</ins><span class="cx">                         mcast_ttl = atoi(argv[3]);
</span><span class="cx">                         if (mcast_ttl < 1 || mcast_ttl > 255) {
</span><span class="cx">                                 mcast_ttl = 1;
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_exprmod_exprc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_expr/mod_expr.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_expr/mod_expr.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_expr/mod_expr.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -54,7 +54,7 @@
</span><span class="cx">         size_t len;
</span><span class="cx">         int ec = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto error;
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_faxmod_faxc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_fax/mod_fax.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_fax/mod_fax.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_fax/mod_fax.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -133,7 +133,7 @@
</span><span class="cx">                 break;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(msg)) {
</del><ins>+        if (!zstr(msg)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, fs_log_level, "%s", msg);
</span><span class="cx">         }
</span><span class="cx"> }
</span><span class="lines">@@ -511,7 +511,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 pvt->filename = switch_core_session_strdup(session, data);
</span><span class="cx">                 if (pvt->app_mode == FUNCTION_TX) {
</span><span class="cx">                         if ((switch_file_exists(pvt->filename, switch_core_session_get_pool(session)) != SWITCH_STATUS_SUCCESS)) {
</span><span class="lines">@@ -706,11 +706,11 @@
</span><span class="cx">                                 const char *name = switch_xml_attr(x_list, "name");
</span><span class="cx">                                 const char *value = switch_xml_attr(x_list, "value");
</span><span class="cx">
</span><del>-                                if (switch_strlen_zero(name)) {
</del><ins>+                                if (zstr(name)) {
</ins><span class="cx">                                         continue;
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (switch_strlen_zero(value)) {
</del><ins>+                                if (zstr(value)) {
</ins><span class="cx">                                         continue;
</span><span class="cx">                                 }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_fifomod_fifoc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_fifo/mod_fifo.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_fifo/mod_fifo.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_fifo/mod_fifo.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -146,7 +146,7 @@
</span><span class="cx">         return SWITCH_STATUS_SUCCESS;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-#define check_string(s) if (!switch_strlen_zero(s) && !strcasecmp(s, "undef")) { s = NULL; }
</del><ins>+#define check_string(s) if (!zstr(s) && !strcasecmp(s, "undef")) { s = NULL; }
</ins><span class="cx">
</span><span class="cx"> static int node_consumer_wait_count(fifo_node_t *node)
</span><span class="cx"> {
</span><span class="lines">@@ -297,7 +297,7 @@
</span><span class="cx">                 if (switch_odbc_handle_exec(globals.master_odbc, sql, &stmt) != SWITCH_ODBC_SUCCESS) {
</span><span class="cx">                         
</span><span class="cx">                         err_str = switch_odbc_handle_get_error(globals.master_odbc, stmt);
</span><del>-                        if (!switch_strlen_zero(err_str)) {
</del><ins>+                        if (!zstr(err_str)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "ERR: [%s]\n[%s]\n", sql, switch_str_nil(err_str));
</span><span class="cx">                         }
</span><span class="cx">                         switch_safe_free(err_str);
</span><span class="lines">@@ -752,7 +752,7 @@
</span><span class="cx">         int argc;
</span><span class="cx">         uint32_t priority = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto fail;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -819,7 +819,7 @@
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No Args\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -1139,7 +1139,7 @@
</span><span class="cx">                 fifo_strategy_t strat = STRAT_WAITING_LONGER;
</span><span class="cx">                 char *url = NULL;
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(strat_str)) {
</del><ins>+                if (!zstr(strat_str)) {
</ins><span class="cx">                         if (!strcasecmp(strat_str, "more_ppl")) {
</span><span class="cx">                                 strat = STRAT_MORE_PPL;
</span><span class="cx">                         } else if (!strcasecmp(strat_str, "waiting_longer")) {
</span><span class="lines">@@ -1489,7 +1489,7 @@
</span><span class="cx">                                 fifo_consumer_wrapup_sound = switch_channel_get_variable(channel, "fifo_consumer_wrapup_sound");
</span><span class="cx">                                 fifo_consumer_wrapup_key = switch_channel_get_variable(channel, "fifo_consumer_wrapup_key");
</span><span class="cx">                                 sfifo_consumer_wrapup_time = switch_channel_get_variable(channel, "fifo_consumer_wrapup_time");
</span><del>-                                if (!switch_strlen_zero(sfifo_consumer_wrapup_time)){
</del><ins>+                                if (!zstr(sfifo_consumer_wrapup_time)){
</ins><span class="cx">                                         fifo_consumer_wrapup_time = atoi(sfifo_consumer_wrapup_time);
</span><span class="cx">                                 } else {
</span><span class="cx">                                         fifo_consumer_wrapup_time = 5000;
</span><span class="lines">@@ -1497,7 +1497,7 @@
</span><span class="cx">
</span><span class="cx">                                 memset(buf, 0, sizeof(buf));
</span><span class="cx">
</span><del>-                                if (fifo_consumer_wrapup_time || !switch_strlen_zero(fifo_consumer_wrapup_key)) {
</del><ins>+                                if (fifo_consumer_wrapup_time || !zstr(fifo_consumer_wrapup_key)) {
</ins><span class="cx">                                         switch_channel_set_variable(channel, "fifo_status", "WRAPUP");
</span><span class="cx">                                         if (switch_event_create_subclass(&event, SWITCH_EVENT_CUSTOM, FIFO_EVENT) == SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                                                 switch_channel_event_set_data(channel, event);
</span><span class="lines">@@ -1507,7 +1507,7 @@
</span><span class="cx">                                         }
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(fifo_consumer_wrapup_sound)) {
</del><ins>+                                if (!zstr(fifo_consumer_wrapup_sound)) {
</ins><span class="cx">                                         memset(&args, 0, sizeof(args));
</span><span class="cx">                                         args.buf = buf;
</span><span class="cx">                                         args.buflen = sizeof(buf);
</span><span class="lines">@@ -1518,7 +1518,7 @@
</span><span class="cx">                                         wrapup_time_started = switch_micro_time_now();
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(fifo_consumer_wrapup_key) && strcmp(buf, fifo_consumer_wrapup_key)) {
</del><ins>+                                if (!zstr(fifo_consumer_wrapup_key) && strcmp(buf, fifo_consumer_wrapup_key)) {
</ins><span class="cx">                                         while(switch_channel_ready(channel)) {
</span><span class="cx">                                                 char terminator = 0;
</span><span class="cx">                                                 
</span><span class="lines">@@ -1537,7 +1537,7 @@
</span><span class="cx">                                                 }
</span><span class="cx">
</span><span class="cx">                                         }
</span><del>-                                } else if (fifo_consumer_wrapup_time && (switch_strlen_zero(fifo_consumer_wrapup_key) || !strcmp(buf, fifo_consumer_wrapup_key))) {
</del><ins>+                                } else if (fifo_consumer_wrapup_time && (zstr(fifo_consumer_wrapup_key) || !strcmp(buf, fifo_consumer_wrapup_key))) {
</ins><span class="cx">                                         while(switch_channel_ready(channel)) {
</span><span class="cx">                                                 wrapup_time_elapsed = (switch_micro_time_now() - wrapup_time_started) / 1000;
</span><span class="cx">                                                 if (wrapup_time_elapsed > fifo_consumer_wrapup_time) {
</span><span class="lines">@@ -1761,12 +1761,12 @@
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 data = strdup(cmd);
</span><span class="cx">                 switch_assert(data);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || (argc = switch_separate_string(data, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) < 1 || !argv[0]) {
</del><ins>+        if (zstr(cmd) || (argc = switch_separate_string(data, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) < 1 || !argv[0]) {
</ins><span class="cx">                 stream->write_function(stream, "%s\n", FIFO_API_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -1897,7 +1897,7 @@
</span><span class="cx">                         var = (char *) switch_xml_attr_soft(param, "name");
</span><span class="cx">                         val = (char *) switch_xml_attr_soft(param, "value");
</span><span class="cx">
</span><del>-                        if (!strcasecmp(var, "odbc-dsn") && !switch_strlen_zero(val)) {
</del><ins>+                        if (!strcasecmp(var, "odbc-dsn") && !zstr(val)) {
</ins><span class="cx">                                 if (switch_odbc_available()) {
</span><span class="cx">                                         globals.odbc_dsn = switch_core_strdup(globals.pool, val);
</span><span class="cx">                                         if ((odbc_user = strchr(globals.odbc_dsn, ':'))) {
</span><span class="lines">@@ -1915,7 +1915,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(globals.odbc_dsn) || switch_strlen_zero(odbc_user) || switch_strlen_zero(odbc_pass)) {
</del><ins>+        if (zstr(globals.odbc_dsn) || zstr(odbc_user) || zstr(odbc_pass)) {
</ins><span class="cx">                 globals.dbname = "fifo";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2190,7 +2190,7 @@
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)){
</del><ins>+        if (zstr(cmd)){
</ins><span class="cx">                 stream->write_function(stream, "-USAGE: %s\n", FIFO_MEMBER_API_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_lcrmod_lcrc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_lcr/mod_lcr.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -174,7 +174,7 @@
</span><span class="cx">         char *dst_regex = NULL;
</span><span class="cx">         switch_channel_t *channel = NULL;
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(cid)) {
</del><ins>+        if (!zstr(cid)) {
</ins><span class="cx">                 len = strlen(cid);
</span><span class="cx">         } else {
</span><span class="cx">                 goto done;
</span><span class="lines">@@ -275,12 +275,12 @@
</span><span class="cx">                 }
</span><span class="cx">         }        
</span><span class="cx">         codec = "";
</span><del>-        if (!switch_strlen_zero(cur_route->codec)) {
</del><ins>+        if (!zstr(cur_route->codec)) {
</ins><span class="cx">                 codec = switch_core_sprintf(pool, ",absolute_codec_string=%s", cur_route->codec);
</span><span class="cx">         }
</span><span class="cx">         
</span><span class="cx">         cid = "";
</span><del>-        if (!switch_strlen_zero(cur_route->cid)) {
</del><ins>+        if (!zstr(cur_route->cid)) {
</ins><span class="cx">                 cid = switch_core_sprintf(pool, ",origination_caller_id_number=%s",
</span><span class="cx">                                                                  do_cid(pool, cur_route->cid, caller_id, session));
</span><span class="cx">         }
</span><span class="lines">@@ -292,7 +292,7 @@
</span><span class="cx">                                                                          cur_route->carrier_name);
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(cur_route->user_rate_str)) {
</del><ins>+        if (zstr(cur_route->user_rate_str)) {
</ins><span class="cx">                 user_rate = "";
</span><span class="cx">         } else {
</span><span class="cx">                 user_rate = switch_core_sprintf(pool, ",lcr_user_rate=%s", cur_route->user_rate_str);
</span><span class="lines">@@ -312,7 +312,7 @@
</span><span class="cx"> {
</span><span class="cx">         profile_t *profile = NULL;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(profile_name)) {
</del><ins>+        if (zstr(profile_name)) {
</ins><span class="cx">                 profile = globals.default_profile;
</span><span class="cx">         } else if (!(profile = switch_core_hash_find(globals.profile_hash, profile_name))) {
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error invalid profile %s\n", profile_name);
</span><span class="lines">@@ -555,7 +555,7 @@
</span><span class="cx">                 return SWITCH_STATUS_GENERR;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(argv[LCR_GW_PREFIX_PLACE]) && switch_strlen_zero(argv[LCR_GW_SUFFIX_PLACE]) ) {
</del><ins>+        if (zstr(argv[LCR_GW_PREFIX_PLACE]) && zstr(argv[LCR_GW_SUFFIX_PLACE]) ) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING,
</span><span class="cx">                                                                 "There's no way to dial this Gateway: Carrier: \"%s\" Prefix: \"%s\", Suffix \"%s\"\n",
</span><span class="cx">                                                                 switch_str_nil(argv[LCR_CARRIER_PLACE]),
</span><span class="lines">@@ -737,7 +737,7 @@
</span><span class="cx">         switch_assert(cb_struct->lookup_number != NULL);
</span><span class="cx">
</span><span class="cx">         digits_copy = string_digitsonly(cb_struct->pool, digits);
</span><del>-        if (switch_strlen_zero(digits_copy)) {
</del><ins>+        if (zstr(digits_copy)) {
</ins><span class="cx">                 return SWITCH_STATUS_GENERR;
</span><span class="cx">         }
</span><span class="cx">         
</span><span class="lines">@@ -862,7 +862,7 @@
</span><span class="cx">                         char *val = NULL;
</span><span class="cx">                         var = (char *) switch_xml_attr_soft(param, "name");
</span><span class="cx">                         val = (char *) switch_xml_attr_soft(param, "value");
</span><del>-                        if (!strcasecmp(var, "odbc-dsn") && !switch_strlen_zero(val)) {
</del><ins>+                        if (!strcasecmp(var, "odbc-dsn") && !zstr(val)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "odbc_dsn is %s\n", val);
</span><span class="cx">                                 globals.odbc_dsn = switch_core_strdup(globals.pool, val);
</span><span class="cx">                                 if ((odbc_user = strchr(globals.odbc_dsn, ':'))) {
</span><span class="lines">@@ -922,13 +922,13 @@
</span><span class="cx">                                 var = (char *) switch_xml_attr_soft(param, "name");
</span><span class="cx">                                 val = (char *) switch_xml_attr_soft(param, "value");
</span><span class="cx">                                 
</span><del>-                                if (!strcasecmp(var, "order_by") && !switch_strlen_zero(val)) {
</del><ins>+                                if (!strcasecmp(var, "order_by") && !zstr(val)) {
</ins><span class="cx">                                         thisorder = &order_by;
</span><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "param val is %s\n", val);
</span><span class="cx">                                         if ((argc = switch_separate_string(val, ',', argv, (sizeof(argv) / sizeof(argv[0]))))) {
</span><span class="cx">                                                 for (x=0; x<argc; x++) {
</span><span class="cx">                                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "arg #%d/%d is %s\n", x, argc, argv[x]);
</span><del>-                                                        if (!switch_strlen_zero(argv[x])) {
</del><ins>+                                                        if (!zstr(argv[x])) {
</ins><span class="cx">                                                                 if (!strcasecmp(argv[x], "quality")) {
</span><span class="cx">                                                                         thisorder->write_function(thisorder, "%s quality DESC", comma);
</span><span class="cx">                                                                 } else if (!strcasecmp(argv[x], "reliability")) {
</span><span class="lines">@@ -951,40 +951,40 @@
</span><span class="cx">                                                         thisorder->write_function(thisorder, "%s %s", comma, val);
</span><span class="cx">                                                 }
</span><span class="cx">                                         }
</span><del>-                                } else if (!strcasecmp(var, "id") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "id") && !zstr(val)) {
</ins><span class="cx">                                         id_s = val;
</span><del>-                                } else if (!strcasecmp(var, "custom_sql") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "custom_sql") && !zstr(val)) {
</ins><span class="cx">                                         custom_sql = val;
</span><del>-                                } else if (!strcasecmp(var, "reorder_by_rate") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "reorder_by_rate") && !zstr(val)) {
</ins><span class="cx">                                         reorder_by_rate = val;
</span><del>-                                } else if (!strcasecmp(var, "info_in_headers") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "info_in_headers") && !zstr(val)) {
</ins><span class="cx">                                         info_in_headers = val;
</span><del>-                                } else if (!strcasecmp(var, "quote_in_list") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "quote_in_list") && !zstr(val)) {
</ins><span class="cx">                                         quote_in_list = val;
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="cx">                         
</span><del>-                        if (switch_strlen_zero(name)) {
</del><ins>+                        if (zstr(name)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "No name specified.\n");
</span><span class="cx">                         } else {
</span><span class="cx">                                 profile = switch_core_alloc(globals.pool, sizeof(*profile));
</span><span class="cx">                                 memset(profile, 0, sizeof(profile_t));
</span><span class="cx">                                 profile->name = switch_core_strdup(globals.pool, name);
</span><span class="cx">                                 
</span><del>-                                if (!switch_strlen_zero((char *)order_by.data)) {
</del><ins>+                                if (!zstr((char *)order_by.data)) {
</ins><span class="cx">                                         profile->order_by = switch_core_strdup(globals.pool, (char *)order_by.data);
</span><span class="cx">                                 } else {
</span><span class="cx">                                         /* default to rate */
</span><span class="cx">                                         profile->order_by = ", ${lcr_rate_field}";
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(id_s)) {
</del><ins>+                                if (!zstr(id_s)) {
</ins><span class="cx">                                         profile->id = (uint16_t)atoi(id_s);
</span><span class="cx">                                 }
</span><span class="cx">                                 
</span><span class="cx">                                 /* SWITCH_STANDARD_STREAM doesn't use pools. but we only have to free sql_stream.data */
</span><span class="cx">                                 SWITCH_STANDARD_STREAM(sql_stream);
</span><del>-                                if (switch_strlen_zero(custom_sql)) {
</del><ins>+                                if (zstr(custom_sql)) {
</ins><span class="cx">                                         /* use default sql */
</span><span class="cx">                                         sql_stream.write_function(&sql_stream,
</span><span class="cx">                                                                                          "SELECT l.digits, c.carrier_name, l.${lcr_rate_field}, cg.prefix AS gw_prefix, cg.suffix AS gw_suffix, l.lead_strip, l.trail_strip, l.prefix, l.suffix "
</span><span class="lines">@@ -1046,15 +1046,15 @@
</span><span class="cx">                                 }
</span><span class="cx">                                 profile->custom_sql = switch_core_strdup(globals.pool, (char *)custom_sql);
</span><span class="cx">                                 
</span><del>-                                if (!switch_strlen_zero(reorder_by_rate)) {
</del><ins>+                                if (!zstr(reorder_by_rate)) {
</ins><span class="cx">                                         profile->reorder_by_rate = switch_true(reorder_by_rate);
</span><span class="cx">                                 }
</span><span class="cx">                                 
</span><del>-                                if (!switch_strlen_zero(info_in_headers)) {
</del><ins>+                                if (!zstr(info_in_headers)) {
</ins><span class="cx">                                         profile->info_in_headers = switch_true(info_in_headers);
</span><span class="cx">                                 }
</span><span class="cx">                                 
</span><del>-                                if (!switch_strlen_zero(quote_in_list)) {
</del><ins>+                                if (!zstr(quote_in_list)) {
</ins><span class="cx">                                         profile->quote_in_list = switch_true(quote_in_list);
</span><span class="cx">                                 }
</span><span class="cx">                                 
</span><span class="lines">@@ -1124,10 +1124,10 @@
</span><span class="cx">         intralata = switch_channel_get_variable(channel, "intralata");
</span><span class="cx">         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "intrastate channel var is [%s]\n", intrastate);
</span><span class="cx">         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "intralata channel var is [%s]\n", intralata);
</span><del>-        if (!switch_strlen_zero(intralata) && !strcasecmp((char *)intralata, "true")) {
</del><ins>+        if (!zstr(intralata) && !strcasecmp((char *)intralata, "true")) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Select routes based on intralata rates\n");
</span><span class="cx">                 routes.intralata = SWITCH_FALSE;
</span><del>-        } else if (!switch_strlen_zero(intrastate) && !strcasecmp((char *)intrastate, "true")) {
</del><ins>+        } else if (!zstr(intrastate) && !strcasecmp((char *)intrastate, "true")) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Select routes based on intrastate rates\n");
</span><span class="cx">                 routes.intrastate = SWITCH_TRUE;
</span><span class="cx">         } else {
</span><span class="lines">@@ -1214,8 +1214,8 @@
</span><span class="cx">
</span><span class="cx">         intra = switch_channel_get_variable(channel, "intrastate");
</span><span class="cx">         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "intrastate channel var is [%s]\n",
</span><del>-                                        switch_strlen_zero(intra) ? "undef" : intra);
-        if (switch_strlen_zero(intra) || strcasecmp((char *)intra, "true")) {
</del><ins>+                                        zstr(intra) ? "undef" : intra);
+        if (zstr(intra) || strcasecmp((char *)intra, "true")) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Select routes based on interstate rates\n");
</span><span class="cx">                 routes.intrastate = SWITCH_FALSE;
</span><span class="cx">         } else {
</span><span class="lines">@@ -1308,7 +1308,7 @@
</span><span class="cx">         switch_bool_t as_xml = SWITCH_FALSE;
</span><span class="cx">         int rowcount=0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1354,7 +1354,7 @@
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><del>-                if (switch_strlen_zero(cb_struct.cid)) {
</del><ins>+                if (zstr(cb_struct.cid)) {
</ins><span class="cx">                         cb_struct.cid = "18005551212";
</span><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING
</span><span class="cx">                                                          , "Using default CID [%s]\n", cb_struct.cid
</span><span class="lines">@@ -1480,7 +1480,7 @@
</span><span class="cx">         void *val;
</span><span class="cx">         profile_t *profile;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1497,7 +1497,7 @@
</span><span class="cx">                                 profile = (profile_t *) val;
</span><span class="cx">                                 
</span><span class="cx">                                 stream->write_function(stream, "Name:\t\t%s\n", profile->name);
</span><del>-                                if (switch_strlen_zero(profile->custom_sql)) {
</del><ins>+                                if (zstr(profile->custom_sql)) {
</ins><span class="cx">                                         stream->write_function(stream, " ID:\t\t%d\n", profile->id);
</span><span class="cx">                                         stream->write_function(stream, " order by:\t%s\n", profile->order_by);
</span><span class="cx">                                 } else {
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_limitmod_limitc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_limit/mod_limit.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_limit/mod_limit.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_limit/mod_limit.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -102,7 +102,7 @@
</span><span class="cx">                 if (switch_odbc_handle_exec(globals.master_odbc, sql, &stmt) != SWITCH_ODBC_SUCCESS) {
</span><span class="cx">                         char *err_str;
</span><span class="cx">                         err_str = switch_odbc_handle_get_error(globals.master_odbc, stmt);
</span><del>-                        if (!switch_strlen_zero(err_str)) {
</del><ins>+                        if (!zstr(err_str)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "ERR: [%s]\n[%s]\n", sql, switch_str_nil(err_str));
</span><span class="cx">                         }
</span><span class="cx">                         switch_safe_free(err_str);
</span><span class="lines">@@ -199,7 +199,7 @@
</span><span class="cx">         }
</span><span class="cx">         
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(globals.odbc_dsn) || switch_strlen_zero(odbc_user) || switch_strlen_zero(odbc_pass)) {
</del><ins>+        if (zstr(globals.odbc_dsn) || zstr(odbc_user) || zstr(odbc_pass)) {
</ins><span class="cx">                 globals.dbname = "call_limit";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -447,7 +447,7 @@
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.mutex);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 mydata = strdup(cmd);
</span><span class="cx">                 switch_assert(mydata);
</span><span class="cx">                 argc = switch_separate_string(mydata, '/', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="lines">@@ -518,7 +518,7 @@
</span><span class="cx">         char *mydata = NULL;
</span><span class="cx">         char *sql = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 mydata = switch_core_session_strdup(session, data);
</span><span class="cx">                 argc = switch_separate_string(mydata, '/', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="lines">@@ -567,7 +567,7 @@
</span><span class="cx">         
</span><span class="cx">         switch_mutex_lock(globals.db_hash_mutex);
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 mydata = strdup(data);
</span><span class="cx">                 switch_assert(mydata);
</span><span class="cx">                 argc = switch_separate_string(mydata, '/', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="lines">@@ -621,7 +621,7 @@
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.db_hash_mutex);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 mydata = strdup(cmd);
</span><span class="cx">                 switch_assert(mydata);
</span><span class="cx">                 argc = switch_separate_string(mydata, '/', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="lines">@@ -683,7 +683,7 @@
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.mutex);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 mydata = strdup(cmd);
</span><span class="cx">                 argc = switch_separate_string(mydata, ':', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="lines">@@ -766,7 +766,7 @@
</span><span class="cx">         char *mydata = NULL;
</span><span class="cx">         char *sql;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 mydata = switch_core_session_strdup(session, data);
</span><span class="cx">                 argc = switch_separate_string(mydata, ':', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="lines">@@ -865,7 +865,7 @@
</span><span class="cx">         int max = 0;
</span><span class="cx">         switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 mydata = switch_core_session_strdup(session, data);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="lines">@@ -931,7 +931,7 @@
</span><span class="cx">         int max = -1;
</span><span class="cx">
</span><span class="cx">         /* Parse application data */
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 mydata = switch_core_session_strdup(session, data);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="lines">@@ -958,7 +958,7 @@
</span><span class="cx">         app = argv[3];
</span><span class="cx">         app_arg = argv[4];
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(app)) {
</del><ins>+        if (zstr(app)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Missing application\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -982,7 +982,7 @@
</span><span class="cx">         callback_t cbt = { 0 };
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 mydata = strdup(cmd);
</span><span class="cx">                 switch_assert(mydata);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="lines">@@ -1158,7 +1158,7 @@
</span><span class="cx">         switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="cx">
</span><span class="cx">         /* Parse application data */
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 mydata = switch_core_session_strdup(session, data);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="lines">@@ -1223,7 +1223,7 @@
</span><span class="cx">         int interval = 0;
</span><span class="cx">
</span><span class="cx">         /* Parse application data */
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 mydata = switch_core_session_strdup(session, data);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="lines">@@ -1258,7 +1258,7 @@
</span><span class="cx">         app = argv[3];
</span><span class="cx">         app_arg = argv[4];
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(app)) {
</del><ins>+        if (zstr(app)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Missing application\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -1282,7 +1282,7 @@
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.limit_hash_mutex);
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 mydata = strdup(cmd);
</span><span class="cx">                 switch_assert(mydata);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="lines">@@ -1495,7 +1495,7 @@
</span><span class="cx">         switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="cx">
</span><span class="cx">         /* Parse application data */
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 mydata = switch_core_session_strdup(session, data);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="lines">@@ -1556,7 +1556,7 @@
</span><span class="cx">         char *szinterval = NULL;
</span><span class="cx">
</span><span class="cx">         /* Parse application data */
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 mydata = switch_core_session_strdup(session, data);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="lines">@@ -1588,7 +1588,7 @@
</span><span class="cx">         app = argv[3];
</span><span class="cx">         app_arg = argv[4];
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(app)) {
</del><ins>+        if (zstr(app)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Missing application\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -1619,7 +1619,7 @@
</span><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 mydata = strdup(cmd);
</span><span class="cx">                 switch_assert(mydata);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_memcachemod_memcachec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_memcache/mod_memcache.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_memcache/mod_memcache.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_memcache/mod_memcache.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -160,7 +160,7 @@
</span><span class="cx">         memcached_stat_st *stat = NULL;
</span><span class="cx">         memcached_server_st *server_list;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">         
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_nibblebillmod_nibblebillc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_nibblebill/mod_nibblebill.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_nibblebill/mod_nibblebill.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_nibblebill/mod_nibblebill.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -189,22 +189,22 @@
</span><span class="cx">         
</span><span class="cx"> /* Set defaults for any variables still not set */
</span><span class="cx"> setdefaults:
</span><del>-        if (switch_strlen_zero(globals.db_username)) {
</del><ins>+        if (zstr(globals.db_username)) {
</ins><span class="cx">                 set_global_db_username("bandwidth.com");
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(globals.db_password)) {
</del><ins>+        if (zstr(globals.db_password)) {
</ins><span class="cx">                 set_global_db_password("dev");
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(globals.db_dsn)) {
</del><ins>+        if (zstr(globals.db_dsn)) {
</ins><span class="cx">                 set_global_db_dsn("bandwidth.com");
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(globals.percall_action)) {
</del><ins>+        if (zstr(globals.percall_action)) {
</ins><span class="cx">                 set_global_percall_action("hangup");
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(globals.lowbal_action)) {
</del><ins>+        if (zstr(globals.lowbal_action)) {
</ins><span class="cx">                 set_global_lowbal_action("play ding");
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(globals.nobal_action)) {
</del><ins>+        if (zstr(globals.nobal_action)) {
</ins><span class="cx">                 set_global_nobal_action("hangup");
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -722,7 +722,7 @@
</span><span class="cx">         char *lbuf = NULL;
</span><span class="cx">         char *argv[3] = { 0 };
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (lbuf = strdup(data))
</del><ins>+        if (!zstr(data) && (lbuf = strdup(data))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ' ', argv, (sizeof(argv) / sizeof(argv[0]))))) {
</span><span class="cx">                 if (!strcasecmp(argv[0], "adjust") && argc == 2) {
</span><span class="cx">                         nibblebill_adjust(session, (float)atof(argv[1]));
</span><span class="lines">@@ -751,9 +751,9 @@
</span><span class="cx">         char *mycmd = NULL, *argv[3] = { 0 };
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><del>-                if ((argc == 2 || argc == 3) && !switch_strlen_zero(argv[0])) {
</del><ins>+                if ((argc == 2 || argc == 3) && !zstr(argv[0])) {
</ins><span class="cx">                         char *uuid = argv[0];
</span><span class="cx">                         if ((psession = switch_core_session_locate(uuid))) {
</span><span class="cx">                                 switch_channel_t *channel;
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_rssmod_rssc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_rss/mod_rss.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_rss/mod_rss.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_rss/mod_rss.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -234,7 +234,7 @@
</span><span class="cx">
</span><span class="cx">         switch_channel_answer(channel);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 if ((mydata = switch_core_session_strdup(session, data))) {
</span><span class="cx">                         argc = switch_separate_string(mydata, ' ', argv, sizeof(argv) / sizeof(argv[0]));
</span><span class="cx">
</span><span class="lines">@@ -394,7 +394,7 @@
</span><span class="cx">
</span><span class="cx">                 err = switch_xml_error(xml);
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(err)) {
</del><ins>+                if (!zstr(err)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "Error [%s]\n", err);
</span><span class="cx">                         goto finished;
</span><span class="cx">                 }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_soundtouchmod_soundtouchcpp"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_soundtouch/mod_soundtouch.cpp (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_soundtouch/mod_soundtouch.cpp        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_soundtouch/mod_soundtouch.cpp        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -255,7 +255,7 @@
</span><span class="cx">         int x;
</span><span class="cx">
</span><span class="cx">         if ((bug = (switch_media_bug_t *) switch_channel_get_private(channel, "_soundtouch_"))) {
</span><del>-                if (!switch_strlen_zero(data) && !strcasecmp(data, "stop")) {
</del><ins>+                if (!zstr(data) && !strcasecmp(data, "stop")) {
</ins><span class="cx">                         switch_channel_set_private(channel, "_soundtouch_", NULL);
</span><span class="cx">                         switch_core_media_bug_remove(session, &bug);
</span><span class="cx">                 } else {
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_spymod_spyc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_spy/mod_spy.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_spy/mod_spy.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_spy/mod_spy.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -188,7 +188,7 @@
</span><span class="cx">         char* argv[2] = {0};
</span><span class="cx">         char* params = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (params = switch_core_session_strdup(session,data))) {
</del><ins>+        if (!zstr(data) && (params = switch_core_session_strdup(session,data))) {
</ins><span class="cx">                 if ((argc = switch_separate_string(params, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) >= 1) {
</span><span class="cx">
</span><span class="cx">                         switch_channel_t *channel = switch_core_session_get_channel(session);
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_stressmod_stresscpp"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_stress/mod_stress.cpp (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_stress/mod_stress.cpp        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_stress/mod_stress.cpp        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -206,7 +206,7 @@
</span><span class="cx">         int x = 0;
</span><span class="cx">
</span><span class="cx">         if ((bug = (switch_media_bug_t *) switch_channel_get_private(channel, "_stress_"))) {
</span><del>-                if (!switch_strlen_zero(data) && !strcasecmp(data, "stop")) {
</del><ins>+                if (!zstr(data) && !strcasecmp(data, "stop")) {
</ins><span class="cx">                         switch_channel_set_private(channel, "_stress_", NULL);
</span><span class="cx">                         switch_core_media_bug_remove(session, &bug);
</span><span class="cx">                 } else {
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_valet_parkingmod_valet_parkingc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_valet_parking/mod_valet_parking.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_valet_parking/mod_valet_parking.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_valet_parking/mod_valet_parking.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -115,7 +115,7 @@
</span><span class="cx">         char dtmf_buf[128] = "";
</span><span class="cx">         int is_auto = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data) && (lbuf = switch_core_session_strdup(session, data))
</del><ins>+        if (!zstr(data) && (lbuf = switch_core_session_strdup(session, data))
</ins><span class="cx">                 && (argc = switch_separate_string(lbuf, ' ', argv, (sizeof(argv) / sizeof(argv[0])))) >= 2) {
</span><span class="cx">                 char *lot_name = argv[0];
</span><span class="cx">                 char *ext = argv[1];
</span><span class="lines">@@ -311,7 +311,7 @@
</span><span class="cx">                 name = (char *) var;
</span><span class="cx">                 lot = (valet_lot_t *) val;
</span><span class="cx">                 
</span><del>-                if (!switch_strlen_zero(cmd) && strcasecmp(cmd, name)) continue;
</del><ins>+                if (!zstr(cmd) && strcasecmp(cmd, name)) continue;
</ins><span class="cx">                 
</span><span class="cx">                 stream->write_function(stream, " <lot name=\"%s\">\n", name);
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_vmdmod_vmdc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_vmd/mod_vmd.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_vmd/mod_vmd.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_vmd/mod_vmd.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -624,7 +624,7 @@
</span><span class="cx"> int i;
</span><span class="cx">
</span><span class="cx"> /* No command? Display usage */
</span><del>- if (switch_strlen_zero(cmd)) {
</del><ins>+ if (zstr(cmd)) {
</ins><span class="cx"> stream->write_function(stream, "-USAGE: %s\n", VMD_SYNTAX);
</span><span class="cx"> return SWITCH_STATUS_SUCCESS;
</span><span class="cx"> }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodapplicationsmod_voicemailmod_voicemailc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/applications/mod_voicemail/mod_voicemail.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -669,7 +669,7 @@
</span><span class="cx">                 switch_thread_rwlock_create(&profile->rwlock, pool);
</span><span class="cx">                 profile->name = switch_core_strdup(pool, profile_name);
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(profile->odbc_dsn)) {
</del><ins>+                if (!zstr(profile->odbc_dsn)) {
</ins><span class="cx">                         if ((profile->odbc_user = strchr(profile->odbc_dsn, ':'))) {
</span><span class="cx">                                 *(profile->odbc_user++) = '\0';
</span><span class="cx">                                 if ((profile->odbc_pass = strchr(profile->odbc_user, ':'))) {
</span><span class="lines">@@ -1571,7 +1571,7 @@
</span><span class="cx">                                 char *sql = switch_mprintf("update voicemail_msgs set flags='delete' where uuid='%s'", cbt->uuid);
</span><span class="cx">                                 vm_execute_sql(profile, sql, profile->mutex);
</span><span class="cx">                                 switch_safe_free(sql);
</span><del>-                                if (!strcmp(input, profile->email_key) && !switch_strlen_zero(cbt->email)) {
</del><ins>+                                if (!strcmp(input, profile->email_key) && !zstr(cbt->email)) {
</ins><span class="cx">                                         switch_event_t *event;
</span><span class="cx">                                         char *from;
</span><span class="cx">                                         char *headers, *header_string;
</span><span class="lines">@@ -1631,13 +1631,13 @@
</span><span class="cx">                                         switch_channel_set_variable(channel, "voicemail_message_len", duration_str);
</span><span class="cx">                                         switch_channel_set_variable(channel, "voicemail_email", cbt->email);
</span><span class="cx">
</span><del>-                                        if (switch_strlen_zero(profile->email_headers)) {
</del><ins>+                                        if (zstr(profile->email_headers)) {
</ins><span class="cx">                                                 from = switch_core_session_sprintf(session, "%s@%s", cbt->user, cbt->domain);
</span><span class="cx">                                         } else {
</span><span class="cx">                                                 from = switch_channel_expand_variables(channel, profile->email_from);
</span><span class="cx">                                         }
</span><span class="cx">
</span><del>-                                        if (switch_strlen_zero(profile->email_headers)) {
</del><ins>+                                        if (zstr(profile->email_headers)) {
</ins><span class="cx">                                                 headers = switch_core_session_sprintf(session,
</span><span class="cx">                                                                                                                          "From: FreeSWITCH mod_voicemail <%s@%s>\nSubject: Voicemail from %s %s\nX-Priority: %d",
</span><span class="cx">                                                                                                                          cbt->user, cbt->domain, cbt->cid_name, cbt->cid_number, priority);
</span><span class="lines">@@ -1818,7 +1818,7 @@
</span><span class="cx">                                         switch_snprintf(msg_count, sizeof(msg_count), "%d:urgent-new", total_new_urgent_messages);
</span><span class="cx">                                         TRY_CODE(switch_ivr_phrase_macro(session, VM_MESSAGE_COUNT_MACRO, msg_count, NULL, &folder_args));
</span><span class="cx">                                         informed++;
</span><del>-                                        if (!switch_strlen_zero_buf(global_buf)) {
</del><ins>+                                        if (!zstr_buf(global_buf)) {
</ins><span class="cx">                                                 vm_check_state = VM_CHECK_MENU;
</span><span class="cx">                                                 continue;
</span><span class="cx">                                         }
</span><span class="lines">@@ -1827,7 +1827,7 @@
</span><span class="cx">                                         switch_snprintf(msg_count, sizeof(msg_count), "%d:new", total_new_messages);
</span><span class="cx">                                         TRY_CODE(switch_ivr_phrase_macro(session, VM_MESSAGE_COUNT_MACRO, msg_count, NULL, &folder_args));
</span><span class="cx">                                         informed++;
</span><del>-                                        if (!switch_strlen_zero_buf(global_buf)) {
</del><ins>+                                        if (!zstr_buf(global_buf)) {
</ins><span class="cx">                                                 vm_check_state = VM_CHECK_MENU;
</span><span class="cx">                                                 continue;
</span><span class="cx">                                         }
</span><span class="lines">@@ -2047,7 +2047,7 @@
</span><span class="cx">                                 char input[10] = "";
</span><span class="cx">                                 char key_buf[80] = "";
</span><span class="cx">                                 play_msg_type = MSG_NONE;
</span><del>-                                if (!switch_strlen_zero_buf(global_buf)) {
</del><ins>+                                if (!zstr_buf(global_buf)) {
</ins><span class="cx">                                         switch_set_string(input, global_buf);
</span><span class="cx">                                         *global_buf = '\0';
</span><span class="cx">                                         status = SWITCH_STATUS_SUCCESS;
</span><span class="lines">@@ -2157,8 +2157,8 @@
</span><span class="cx">                                         } else if (!auth && !thepass && !strcasecmp(var, "password")) {
</span><span class="cx">                                                 thepass = switch_core_session_strdup(session, val);
</span><span class="cx">                                         } else if (!auth && !strcasecmp(var, "vm-password")) {
</span><del>-                                                if (!switch_strlen_zero(val) && !strcasecmp(val, "user-choose")) {
-                                                        if (switch_strlen_zero(cbt.password)) {
</del><ins>+                                                if (!zstr(val) && !strcasecmp(val, "user-choose")) {
+                                                        if (zstr(cbt.password)) {
</ins><span class="cx">                                                                 auth = 1;
</span><span class="cx">                                                         } else {
</span><span class="cx">                                                                 thepass = switch_core_session_strdup(session, val);
</span><span class="lines">@@ -2202,12 +2202,12 @@
</span><span class="cx">                                         thehash = vmhash;
</span><span class="cx">                                 }
</span><span class="cx">                                 
</span><del>-                                if (!auth && !thepass && !switch_strlen_zero(cbt.password)) {
</del><ins>+                                if (!auth && !thepass && !zstr(cbt.password)) {
</ins><span class="cx">                                         thepass = cbt.password;
</span><span class="cx">                                 }
</span><span class="cx">
</span><span class="cx">                                 if (!auth) {
</span><del>-                                        if (!switch_strlen_zero(cbt.password) && !strcmp(cbt.password, mypass)) {
</del><ins>+                                        if (!zstr(cbt.password) && !strcmp(cbt.password, mypass)) {
</ins><span class="cx">                                                 auth++;
</span><span class="cx">                                         } else if (!thepass) {
</span><span class="cx">                                                 auth++;
</span><span class="lines">@@ -2234,9 +2234,9 @@
</span><span class="cx">                                 
</span><span class="cx">                                 if (auth) {
</span><span class="cx">                                         if (!dir_path) {
</span><del>-                                                if (!switch_strlen_zero(vm_storage_dir)) {
</del><ins>+                                                if (!zstr(vm_storage_dir)) {
</ins><span class="cx">                                                         dir_path = switch_core_session_sprintf(session, "%s%s%s", vm_storage_dir, SWITCH_PATH_SEPARATOR, myid);
</span><del>-                                                } else if ( !switch_strlen_zero(profile->storage_dir) ) {
</del><ins>+                                                } else if ( !zstr(profile->storage_dir) ) {
</ins><span class="cx">                                                         dir_path = switch_core_session_sprintf(session, "%s%s%s%s%s", profile->storage_dir, SWITCH_PATH_SEPARATOR, domain_name, SWITCH_PATH_SEPARATOR, myid);
</span><span class="cx">                                                 } else {
</span><span class="cx">                                                         dir_path = switch_core_session_sprintf(session, "%s%svoicemail%s%s%s%s%s%s", SWITCH_GLOBAL_dirs.storage_dir,
</span><span class="lines">@@ -2389,9 +2389,9 @@
</span><span class="cx">
</span><span class="cx">         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Deliver VM to %s@%s\n", myid, domain_name);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(vm_storage_dir)) {
</del><ins>+        if (!zstr(vm_storage_dir)) {
</ins><span class="cx">                 dir_path = switch_mprintf("%s%s%s", vm_storage_dir, SWITCH_PATH_SEPARATOR, myid);
</span><del>-        } else if (!switch_strlen_zero(profile->storage_dir)) {
</del><ins>+        } else if (!zstr(profile->storage_dir)) {
</ins><span class="cx">                 dir_path = switch_mprintf("%s%s%s%s%s", profile->storage_dir, SWITCH_PATH_SEPARATOR, domain_name, SWITCH_PATH_SEPARATOR, myid);
</span><span class="cx">         } else {
</span><span class="cx">                 dir_path = switch_mprintf("%s%svoicemail%s%s%s%s%s%s", SWITCH_GLOBAL_dirs.storage_dir,
</span><span class="lines">@@ -2450,7 +2450,7 @@
</span><span class="cx">                 update_mwi(profile, myid, domain_name, myfolder);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (send_mail && !switch_strlen_zero(vm_email) && switch_file_exists(file_path, pool) == SWITCH_STATUS_SUCCESS) {
</del><ins>+        if (send_mail && !zstr(vm_email) && switch_file_exists(file_path, pool) == SWITCH_STATUS_SUCCESS) {
</ins><span class="cx">                 switch_event_t *event;
</span><span class="cx">                 char *from;
</span><span class="cx">                 char *body;
</span><span class="lines">@@ -2472,7 +2472,7 @@
</span><span class="cx">                 message_count(profile, myid, domain_name, myfolder, &total_new_messages, &total_saved_messages,
</span><span class="cx">                                          &total_new_urgent_messages, &total_saved_urgent_messages);
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(vm_timezone) || (switch_strftime_tz(vm_timezone, profile->date_fmt, date, sizeof(date), 0) != SWITCH_STATUS_SUCCESS)) {
</del><ins>+                if (zstr(vm_timezone) || (switch_strftime_tz(vm_timezone, profile->date_fmt, date, sizeof(date), 0) != SWITCH_STATUS_SUCCESS)) {
</ins><span class="cx">                         switch_time_exp_lt(&tm, switch_micro_time_now());
</span><span class="cx">                         switch_strftime(date, &retsize, sizeof(date), profile->date_fmt, &tm);
</span><span class="cx">                 }
</span><span class="lines">@@ -2510,7 +2510,7 @@
</span><span class="cx">
</span><span class="cx">                 switch_event_add_header_string(params, SWITCH_STACK_BOTTOM, "voicemail_message_len", duration_str);
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(profile->email_from)) {
</del><ins>+                if (zstr(profile->email_from)) {
</ins><span class="cx">                         from = switch_core_sprintf(pool, "%s@%s", myid, domain_name);
</span><span class="cx">                 } else {
</span><span class="cx">                         from = switch_event_expand_headers(params, profile->email_from);
</span><span class="lines">@@ -2518,7 +2518,7 @@
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">                 if (send_main) {
</span><del>-                        if (switch_strlen_zero(profile->email_headers)) {
</del><ins>+                        if (zstr(profile->email_headers)) {
</ins><span class="cx">                                 headers = switch_mprintf(
</span><span class="cx">                                                                                  "From: FreeSWITCH mod_voicemail <%s@%s>\n"
</span><span class="cx">                                                                                  "Subject: Voicemail from %s %s\nX-Priority: %d",
</span><span class="lines">@@ -2570,7 +2570,7 @@
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">                 if (send_notify) {
</span><del>-                        if (switch_strlen_zero(profile->notify_email_headers)) {
</del><ins>+                        if (zstr(profile->notify_email_headers)) {
</ins><span class="cx">                                 headers = switch_mprintf(
</span><span class="cx">                                                                                  "From: FreeSWITCH mod_voicemail <%s@%s>\n"
</span><span class="cx">                                                                                  "Subject: Voicemail from %s %s\nX-Priority: %d",
</span><span class="lines">@@ -2648,7 +2648,7 @@
</span><span class="cx">         char *box, *path, *cid_num, *cid_name;
</span><span class="cx">         switch_memory_pool_t *pool = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="lines">@@ -2906,17 +2906,17 @@
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (send_main && switch_strlen_zero(vm_email) && !switch_strlen_zero(email_addr)) {
</del><ins>+                        if (send_main && zstr(vm_email) && !zstr(email_addr)) {
</ins><span class="cx">                                 vm_email = switch_core_session_strdup(session, email_addr);
</span><del>-                                if (switch_strlen_zero(vm_email)) {
</del><ins>+                                if (zstr(vm_email)) {
</ins><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "No email address, not going to send email.\n");
</span><span class="cx">                                         send_main = 0;
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (send_notify && switch_strlen_zero(vm_notify_email)) {
</del><ins>+                        if (send_notify && zstr(vm_notify_email)) {
</ins><span class="cx">                                 vm_notify_email = vm_email;
</span><del>-                                if (switch_strlen_zero(vm_notify_email)) {
</del><ins>+                                if (zstr(vm_notify_email)) {
</ins><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "No notify email address, not going to notify.\n");
</span><span class="cx">                                         send_notify = 0;
</span><span class="cx">                                 }
</span><span class="lines">@@ -2944,9 +2944,9 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(vm_storage_dir)) {
</del><ins>+        if (!zstr(vm_storage_dir)) {
</ins><span class="cx">                 dir_path = switch_core_session_sprintf(session, "%s%s%s", vm_storage_dir, SWITCH_PATH_SEPARATOR, id);
</span><del>-        } else if (!switch_strlen_zero(profile->storage_dir)) {
</del><ins>+        } else if (!zstr(profile->storage_dir)) {
</ins><span class="cx">                 dir_path = switch_core_session_sprintf(session, "%s%s%s%s%s", profile->storage_dir, SWITCH_PATH_SEPARATOR, domain_name, SWITCH_PATH_SEPARATOR, id);
</span><span class="cx">         } else {
</span><span class="cx">                 dir_path = switch_core_session_sprintf(session, "%s%svoicemail%s%s%s%s%s%s", SWITCH_GLOBAL_dirs.storage_dir,
</span><span class="lines">@@ -2987,11 +2987,11 @@
</span><span class="cx">
</span><span class="cx">                 switch_ivr_sleep(session, 100, SWITCH_TRUE, NULL);
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(greet_path)) {
</del><ins>+                if (!zstr(greet_path)) {
</ins><span class="cx">                         memset(buf, 0, sizeof(buf));
</span><span class="cx">                         TRY_CODE(switch_ivr_play_file(session, NULL, greet_path, &args));
</span><span class="cx">                 } else {
</span><del>-                        if (!switch_strlen_zero(cbt.name_path)) {
</del><ins>+                        if (!zstr(cbt.name_path)) {
</ins><span class="cx">                                 memset(buf, 0, sizeof(buf));
</span><span class="cx">                                 TRY_CODE(switch_ivr_play_file(session, NULL, cbt.name_path, &args));
</span><span class="cx">                         }
</span><span class="lines">@@ -3010,12 +3010,12 @@
</span><span class="cx"> greet_key_press:
</span><span class="cx"> if (switch_stristr(buf, profile->login_keys)) {
</span><span class="cx"> voicemail_check_main(session, profile, domain_name, id, 0);
</span><del>- } else if (!strcasecmp(buf, profile->operator_key) && !switch_strlen_zero(profile->operator_key)) {
</del><ins>+ } else if (!strcasecmp(buf, profile->operator_key) && !zstr(profile->operator_key)) {
</ins><span class="cx"> int argc;
</span><span class="cx"> char *argv[4];
</span><span class="cx"> char *mycmd;
</span><span class="cx">
</span><del>- if (!switch_strlen_zero(profile->operator_ext) && (mycmd = switch_core_session_strdup(session, profile->operator_ext))) {
</del><ins>+ if (!zstr(profile->operator_ext) && (mycmd = switch_core_session_strdup(session, profile->operator_ext))) {
</ins><span class="cx"> argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx"> if (argc >= 1 && argc <= 4) {
</span><span class="cx"> switch_ivr_session_transfer(session, argv[0], argv[1], argv[2]);
</span><span class="lines">@@ -3024,12 +3024,12 @@
</span><span class="cx"> goto end;
</span><span class="cx"> }
</span><span class="cx"> }
</span><del>- } else if (!strcasecmp(buf, profile->vmain_key) && !switch_strlen_zero(profile->vmain_key)) {
</del><ins>+ } else if (!strcasecmp(buf, profile->vmain_key) && !zstr(profile->vmain_key)) {
</ins><span class="cx"> int argc;
</span><span class="cx"> char *argv[4];
</span><span class="cx"> char *mycmd;
</span><span class="cx">
</span><del>- if (!switch_strlen_zero(profile->vmain_ext) && (mycmd = switch_core_session_strdup(session, profile->vmain_ext))) {
</del><ins>+ if (!zstr(profile->vmain_ext) && (mycmd = switch_core_session_strdup(session, profile->vmain_ext))) {
</ins><span class="cx"> argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx"> if (argc >= 1 && argc <= 4) {
</span><span class="cx"> switch_ivr_session_transfer(session, argv[0], argv[1], argv[2]);
</span><span class="lines">@@ -3177,7 +3177,7 @@
</span><span class="cx">         int x = 0, check = 0, auth = 0;
</span><span class="cx">         switch_channel_t *channel = switch_core_session_get_channel(session);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 mydata = switch_core_session_strdup(session, data);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="lines">@@ -3210,19 +3210,19 @@
</span><span class="cx">                 auth = 1;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(profile_name)) {
</del><ins>+        if (zstr(profile_name)) {
</ins><span class="cx">                 profile_name = switch_channel_get_variable(channel, "voicemail_profile_name");
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(domain_name)) {
</del><ins>+        if (zstr(domain_name)) {
</ins><span class="cx">                 domain_name = switch_channel_get_variable(channel, "voicemail_domain_name");
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(id)) {
</del><ins>+        if (zstr(id)) {
</ins><span class="cx">                 id = switch_channel_get_variable(channel, "voicemail_id");
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(profile_name) || switch_strlen_zero(domain_name)) {
</del><ins>+        if (zstr(profile_name) || zstr(domain_name)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Error Usage: %s\n", VM_USAGE);
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -3254,7 +3254,7 @@
</span><span class="cx">         vm_profile_t *profile;
</span><span class="cx">         char *id, *domain, *p, *profilename = NULL;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "%d", 0);        
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -3271,7 +3271,7 @@
</span><span class="cx">                 id += 4;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(id)) {
</del><ins>+        if (zstr(id)) {
</ins><span class="cx">                 stream->write_function(stream, "%d", 0);
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -3283,7 +3283,7 @@
</span><span class="cx">                         how = p;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(profilename)) {
</del><ins>+                if (!zstr(profilename)) {
</ins><span class="cx">                         if ((profile = get_profile(profilename))) {
</span><span class="cx">                                 message_count(profile, id, domain, "inbox", &total_new_messages, &total_saved_messages,
</span><span class="cx">                                                          &total_new_urgent_messages, &total_saved_urgent_messages);
</span><span class="lines">@@ -3334,7 +3334,7 @@
</span><span class="cx">         char sql[256];
</span><span class="cx">         prefs_callback_t cbt = {{0}};
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "%d", 0);
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -3351,7 +3351,7 @@
</span><span class="cx">                 id += 4;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(id)) {
</del><ins>+        if (zstr(id)) {
</ins><span class="cx">                 stream->write_function(stream, "%d", 0);
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -3363,7 +3363,7 @@
</span><span class="cx">                         how = p;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(profilename) && !(profile = get_profile(profilename))) {
</del><ins>+                if (!zstr(profilename) && !(profile = get_profile(profilename))) {
</ins><span class="cx">                         stream->write_function(stream, "-ERR No such profile\n");
</span><span class="cx">                         goto done;
</span><span class="cx">                 }
</span><span class="lines">@@ -3958,7 +3958,7 @@
</span><span class="cx">                 path_info = switch_event_get_header(stream->param_event, "http-path-info");
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd)) {
</del><ins>+        if (!zstr(cmd)) {
</ins><span class="cx">                 mydata = strdup(cmd);
</span><span class="cx">                 switch_assert(mydata);
</span><span class="cx">                 argc = switch_separate_string(mydata, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span></span></pre></div>
<a id="freeswitchtrunksrcmodasr_ttsmod_cepstralmod_cepstralc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/asr_tts/mod_cepstral/mod_cepstral.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/asr_tts/mod_cepstral/mod_cepstral.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/asr_tts/mod_cepstral/mod_cepstral.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -146,7 +146,7 @@
</span><span class="cx">                 voice_name = NULL;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(voice_name)) {
</del><ins>+        if (zstr(voice_name)) {
</ins><span class="cx">                 /* Find the first voice on the system */
</span><span class="cx">                 if ((cepstral->voice = swift_port_find_first_voice(cepstral->port, NULL, NULL)) == NULL) {
</span><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Failed to find any voices!\n");
</span><span class="lines">@@ -215,18 +215,18 @@
</span><span class="cx">
</span><span class="cx">         cepstral->tts_stream = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(text)) {
</del><ins>+        if (zstr(text)) {
</ins><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">         if (!strncasecmp(text, fp, len)) {
</span><span class="cx">                 text += len;
</span><del>-                if (switch_strlen_zero(text)) {
</del><ins>+                if (zstr(text)) {
</ins><span class="cx">                         return SWITCH_STATUS_FALSE;
</span><span class="cx">                 }
</span><span class="cx">                 swift_port_speak_file(cepstral->port, text, NULL, &cepstral->tts_stream, NULL);
</span><span class="cx">         } else {
</span><span class="cx">                 char *to_say;
</span><del>-                if (switch_strlen_zero(text)) {
</del><ins>+                if (zstr(text)) {
</ins><span class="cx">                         return SWITCH_STATUS_FALSE;
</span><span class="cx">                 }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodasr_ttsmod_pocketsphinxmod_pocketsphinxc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/asr_tts/mod_pocketsphinx/mod_pocketsphinx.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/asr_tts/mod_pocketsphinx/mod_pocketsphinx.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/asr_tts/mod_pocketsphinx/mod_pocketsphinx.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -282,11 +282,11 @@
</span><span class="cx">
</span><span class="cx">                         switch_mutex_lock(ps->flag_mutex);
</span><span class="cx">                         if ((hyp = ps_get_hyp(ps->ps, &ps->score, &ps->uttid))) {
</span><del>-                                if (!switch_strlen_zero(hyp)) {
</del><ins>+                                if (!zstr(hyp)) {
</ins><span class="cx">                                         ps_end_utt(ps->ps);
</span><span class="cx">                                         switch_clear_flag(ps, PSFLAG_READY);
</span><span class="cx">                                         if ((hyp = ps_get_hyp(ps->ps, &ps->score, &ps->uttid))) {
</span><del>-                                                if (switch_strlen_zero(hyp)) {
</del><ins>+                                                if (zstr(hyp)) {
</ins><span class="cx">                                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "Lost the text, never mind....\n");
</span><span class="cx">                                                         ps_start_utt(ps->ps, NULL);
</span><span class="cx">                                                         switch_set_flag(ps, PSFLAG_READY);
</span></span></pre></div>
<a id="freeswitchtrunksrcmodasr_ttsmod_tts_commandlinemod_tts_commandlinec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/asr_tts/mod_tts_commandline/mod_tts_commandline.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/asr_tts/mod_tts_commandline/mod_tts_commandline.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/asr_tts/mod_tts_commandline/mod_tts_commandline.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -75,7 +75,7 @@
</span><span class="cx">                 switch_xml_free(xml);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(globals.command)) {
</del><ins>+        if (zstr(globals.command)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "No command set, please edit %s\n", cf);
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodasr_ttsmod_unimrcpmod_unimrcpc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/asr_tts/mod_unimrcp/mod_unimrcp.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/asr_tts/mod_unimrcp/mod_unimrcp.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/asr_tts/mod_unimrcp/mod_unimrcp.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -490,7 +490,7 @@
</span><span class="cx"> {
</span><span class="cx">         int result = 0;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(text)) {
</del><ins>+        if (!zstr(text)) {
</ins><span class="cx">                 size_t textlen, matchlen;
</span><span class="cx">
</span><span class="cx">                 /* find first non-space character */
</span><span class="lines">@@ -524,7 +524,7 @@
</span><span class="cx">         char *lname = "";
</span><span class="cx">         *audio_queue = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(name)) {
</del><ins>+        if (zstr(name)) {
</ins><span class="cx">                 lname = "";
</span><span class="cx">         } else {
</span><span class="cx">                 lname = switch_core_strdup(pool, name);
</span><span class="lines">@@ -704,7 +704,7 @@
</span><span class="cx"> {
</span><span class="cx">         if (queue) {
</span><span class="cx">                 char *name = queue->name;
</span><del>-                if (switch_strlen_zero(name)) {
</del><ins>+                if (zstr(name)) {
</ins><span class="cx">                         name = "";
</span><span class="cx">                 }
</span><span class="cx">                 if (queue->buffer) {
</span><span class="lines">@@ -779,7 +779,7 @@
</span><span class="cx">         }
</span><span class="cx">         switch_core_hash_init(&schan->params, pool);
</span><span class="cx">         schan->data = NULL;
</span><del>-        if (switch_strlen_zero(name)) {
</del><ins>+        if (zstr(name)) {
</ins><span class="cx">                 schan->name = "";
</span><span class="cx">         } else {
</span><span class="cx">                 schan->name = switch_core_strdup(pool, name);
</span><span class="lines">@@ -1017,7 +1017,7 @@
</span><span class="cx">                 switch_hash_this(hi, &key, NULL, &val);
</span><span class="cx">                 param_name = (char *)key;
</span><span class="cx">                 param_val = (char *)val;
</span><del>-                if (!switch_strlen_zero(param_name) && !switch_strlen_zero(param_val)) {
</del><ins>+                if (!zstr(param_name) && !zstr(param_val)) {
</ins><span class="cx">                         unimrcp_param_id_t *id = (unimrcp_param_id_t *)switch_core_hash_find(schannel->application->param_id_map, param_name);
</span><span class="cx">                         if (id) {
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "(%s) %s: %s\n", schannel->name, param_name, param_val);
</span><span class="lines">@@ -1272,11 +1272,11 @@
</span><span class="cx"> static switch_status_t speech_channel_set_param(speech_channel_t *schannel, const char *param, const char *val)
</span><span class="cx"> {
</span><span class="cx">         switch_mutex_lock(schannel->mutex);
</span><del>-        if (!switch_strlen_zero(param) && val != NULL) {
</del><ins>+        if (!zstr(param) && val != NULL) {
</ins><span class="cx">                 /* check if this is a FreeSWITCH param that needs to be translated to an MRCP param: e.g. voice ==> voice-name */
</span><span class="cx">                 char *mrcp_param = (char *)switch_core_hash_find(schannel->application->fs_param_map, param);
</span><span class="cx">                 char *lcparam = NULL;
</span><del>-                if (switch_strlen_zero(mrcp_param)) {
</del><ins>+                if (zstr(mrcp_param)) {
</ins><span class="cx">                         lcparam = switch_lc_strdup(param);
</span><span class="cx">                         mrcp_param = lcparam;
</span><span class="cx">                 }
</span><span class="lines">@@ -1422,7 +1422,7 @@
</span><span class="cx">         sh->private_info = schannel;
</span><span class="cx">
</span><span class="cx">         /* try to open an MRCP channel */
</span><del>-        if (switch_strlen_zero(profile_name)) {
</del><ins>+        if (zstr(profile_name)) {
</ins><span class="cx">                 profile_name = globals.unimrcp_default_synth_profile;
</span><span class="cx">         }
</span><span class="cx">         profile = (profile_t *)switch_core_hash_find(globals.profiles, profile_name);
</span><span class="lines">@@ -1437,7 +1437,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         /* Set session TTS params */
</span><del>-        if (!switch_strlen_zero(voice_name)) {
</del><ins>+        if (!zstr(voice_name)) {
</ins><span class="cx">                 speech_channel_set_param(schannel, "Voice-Name", voice_name);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1476,7 +1476,7 @@
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">         speech_channel_t *schannel = (speech_channel_t *)sh->private_info;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(text)) {
</del><ins>+        if (zstr(text)) {
</ins><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">         } else {
</span><span class="cx">                 status = synth_channel_speak(schannel, text);
</span><span class="lines">@@ -1900,10 +1900,10 @@
</span><span class="cx">
</span><span class="cx">         /* input timers are started by default unless the start-input-timers=false param is set */
</span><span class="cx">         start_input_timers = (char *)switch_core_hash_find(schannel->params, "start-input-timers");
</span><del>-        r->timers_started = switch_strlen_zero(start_input_timers) || strcasecmp(start_input_timers, "false");
</del><ins>+        r->timers_started = zstr(start_input_timers) || strcasecmp(start_input_timers, "false");
</ins><span class="cx">         
</span><span class="cx">         /* get the cached grammar */
</span><del>-        if (switch_strlen_zero(name)) {
</del><ins>+        if (zstr(name)) {
</ins><span class="cx">                 grammar = r->last_grammar;
</span><span class="cx">         } else {
</span><span class="cx">                 grammar = (grammar_t *)switch_core_hash_find(r->grammars, name);
</span><span class="lines">@@ -1935,7 +1935,7 @@
</span><span class="cx">
</span><span class="cx">         /* set Content-Type */
</span><span class="cx">         mime_type = grammar_type_to_mime(grammar->type, schannel->profile);
</span><del>-        if (switch_strlen_zero(mime_type)) {
</del><ins>+        if (zstr(mime_type)) {
</ins><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -2029,7 +2029,7 @@
</span><span class="cx">                         goto done;
</span><span class="cx">                 }
</span><span class="cx">                 mime_type = grammar_type_to_mime(type, schannel->profile);
</span><del>-                if (switch_strlen_zero(mime_type)) {
</del><ins>+                if (zstr(mime_type)) {
</ins><span class="cx">                         status = SWITCH_STATUS_FALSE;
</span><span class="cx">                         goto done;
</span><span class="cx">                 }
</span><span class="lines">@@ -2084,7 +2084,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(grammar_name)) {
</del><ins>+        if (zstr(grammar_name)) {
</ins><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">         } else {
</span><span class="cx">                 recognizer_data_t *r = (recognizer_data_t *)schannel->data;
</span><span class="lines">@@ -2106,7 +2106,7 @@
</span><span class="cx">         recognizer_data_t *r;
</span><span class="cx">         switch_mutex_lock(schannel->mutex);
</span><span class="cx">         r = (recognizer_data_t *)schannel->data;
</span><del>-        if (!switch_strlen_zero(r->result)) {
</del><ins>+        if (!zstr(r->result)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "(%s) SUCCESS, have result\n", schannel->name);
</span><span class="cx">         } else if (r->start_of_input) {
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "(%s) SUCCESS, start of input\n", schannel->name);
</span><span class="lines">@@ -2180,12 +2180,12 @@
</span><span class="cx">         recognizer_data_t *r;
</span><span class="cx">         switch_mutex_lock(schannel->mutex);
</span><span class="cx">         r = (recognizer_data_t *)schannel->data;
</span><del>-        if (!switch_strlen_zero(r->result)) {
</del><ins>+        if (!zstr(r->result)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "(%s) result is already set\n", schannel->name);
</span><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(result)) {
</del><ins>+        if (zstr(result)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "(%s) result is NULL\n", schannel->name);
</span><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">                 goto done;
</span><span class="lines">@@ -2211,7 +2211,7 @@
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">         recognizer_data_t *r = (recognizer_data_t *)schannel->data;
</span><span class="cx">         switch_mutex_lock(schannel->mutex);
</span><del>-        if (!switch_strlen_zero(r->result)) {
</del><ins>+        if (!zstr(r->result)) {
</ins><span class="cx">                 *result = strdup(r->result);
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "(%s) result:\n\n%s\n", schannel->name, *result);
</span><span class="cx">                 r->result = NULL;
</span><span class="lines">@@ -2248,7 +2248,7 @@
</span><span class="cx">                 switch_hash_this(hi, &key, NULL, &val);
</span><span class="cx">                 param_name = (char *)key;
</span><span class="cx">                 param_val = (char *)val;
</span><del>-                if (!switch_strlen_zero(param_name) && !switch_strlen_zero(param_val)) {
</del><ins>+                if (!zstr(param_name) && !zstr(param_val)) {
</ins><span class="cx">                         unimrcp_param_id_t *id = (unimrcp_param_id_t *)switch_core_hash_find(schannel->application->param_id_map, param_name);
</span><span class="cx">                         if (id) {
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "(%s) \"%s\": \"%s\"\n", schannel->name, param_name, param_val);
</span><span class="lines">@@ -2572,7 +2572,7 @@
</span><span class="cx">         char *filename = NULL;
</span><span class="cx">         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "(%s) grammar = %s, name = %s\n", schannel->name, grammar, name);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(grammar) || switch_strlen_zero(name)) {
</del><ins>+        if (zstr(grammar) || zstr(name)) {
</ins><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -2673,7 +2673,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">         speech_channel_t *schannel = (speech_channel_t *)ah->private_info;
</span><del>-        if (switch_strlen_zero(name) || speech_channel_stop(schannel) != SWITCH_STATUS_SUCCESS ||
</del><ins>+        if (zstr(name) || speech_channel_stop(schannel) != SWITCH_STATUS_SUCCESS ||
</ins><span class="cx">                 recog_channel_unload_grammar(schannel, name) != SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="lines">@@ -3316,13 +3316,13 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         /* set up MRCPv2 connection agent that will be shared with all profiles */
</span><del>-        if (!switch_strlen_zero(globals.unimrcp_max_connection_count)) {
</del><ins>+        if (!zstr(globals.unimrcp_max_connection_count)) {
</ins><span class="cx">                 max_connection_count = atoi(globals.unimrcp_max_connection_count);
</span><span class="cx">         }
</span><span class="cx">         if (max_connection_count <= 0) {
</span><span class="cx">                 max_connection_count = 100;
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(globals.unimrcp_offer_new_connection)) {
</del><ins>+        if (!zstr(globals.unimrcp_offer_new_connection)) {
</ins><span class="cx">                 offer_new_connection = strcasecmp("true", globals.unimrcp_offer_new_connection);
</span><span class="cx">         }
</span><span class="cx">         connection_agent = mrcp_client_connection_agent_create(max_connection_count, offer_new_connection, pool);
</span><span class="lines">@@ -3354,7 +3354,7 @@
</span><span class="cx">                         /* get profile attributes */
</span><span class="cx">                         const char *name = apr_pstrdup(pool, switch_xml_attr(profile, "name"));
</span><span class="cx">                         const char *version = switch_xml_attr(profile, "version");
</span><del>-                        if (switch_strlen_zero(name) || switch_strlen_zero(version)) {
</del><ins>+                        if (zstr(name) || zstr(version)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "<profile> missing name or version attribute\n");
</span><span class="cx">                                 client = NULL;
</span><span class="cx">                                 goto done;
</span><span class="lines">@@ -3381,7 +3381,7 @@
</span><span class="cx">                                 for (param = switch_xml_child(profile, "param"); param; param = switch_xml_next(param)) {
</span><span class="cx">                                         const char *param_name = switch_xml_attr(param, "name");
</span><span class="cx">                                         const char *param_value = switch_xml_attr(param, "value");
</span><del>-                                        if (switch_strlen_zero(param_name)) {
</del><ins>+                                        if (zstr(param_name)) {
</ins><span class="cx">                                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Missing param name\n");
</span><span class="cx">                                                 client = NULL;
</span><span class="cx">                                                 goto done;
</span><span class="lines">@@ -3409,7 +3409,7 @@
</span><span class="cx">                                 for (param = switch_xml_child(profile, "param"); param; param = switch_xml_next(param)) {
</span><span class="cx">                                         const char *param_name = switch_xml_attr(param, "name");
</span><span class="cx">                                         const char *param_value = switch_xml_attr(param, "value");
</span><del>-                                        if (switch_strlen_zero(param_name)) {
</del><ins>+                                        if (zstr(param_name)) {
</ins><span class="cx">                                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Missing param name\n");
</span><span class="cx">                                                 client = NULL;
</span><span class="cx">                                                 goto done;
</span><span class="lines">@@ -3468,11 +3468,11 @@
</span><span class="cx">
</span><span class="cx">         /* get MRCP module configuration */
</span><span class="cx">         mod_unimrcp_do_config();
</span><del>-        if (switch_strlen_zero(globals.unimrcp_default_synth_profile)) {
</del><ins>+        if (zstr(globals.unimrcp_default_synth_profile)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Missing default-tts-profile\n");
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(globals.unimrcp_default_recog_profile)) {
</del><ins>+        if (zstr(globals.unimrcp_default_recog_profile)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Missing default-asr-profile\n");
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="lines">@@ -3575,7 +3575,7 @@
</span><span class="cx">         char log_message[4096] = { 0 }; /* same size as MAX_LOG_ENTRY_SIZE in UniMRCP apt_log.c */
</span><span class="cx">         size_t msglen;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(format)) {
</del><ins>+        if (zstr(format)) {
</ins><span class="cx">                 return TRUE;
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmoddialplansmod_dialplan_asteriskmod_dialplan_asteriskc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/dialplans/mod_dialplan_asterisk/mod_dialplan_asterisk.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/dialplans/mod_dialplan_asterisk/mod_dialplan_asterisk.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/dialplans/mod_dialplan_asterisk/mod_dialplan_asterisk.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -141,7 +141,7 @@
</span><span class="cx">                 caller_profile = switch_channel_get_caller_profile(channel);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!caller_profile || switch_strlen_zero(caller_profile->destination_number)) {
</del><ins>+        if (!caller_profile || zstr(caller_profile->destination_number)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Obtaining Profile!\n");
</span><span class="cx">                 return NULL;
</span><span class="cx">         }
</span><span class="lines">@@ -271,7 +271,7 @@
</span><span class="cx">                                 switch_regex_safe_free(re);
</span><span class="cx">
</span><span class="cx">                                 if (!extension) {
</span><del>-                                        if (switch_strlen_zero(field_data)) {
</del><ins>+                                        if (zstr(field_data)) {
</ins><span class="cx">                                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "No extension!\n");
</span><span class="cx">                                                 break;
</span><span class="cx">                                         }
</span><span class="lines">@@ -313,7 +313,7 @@
</span><span class="cx">         } else {
</span><span class="cx">                 profile = switch_core_get_variable("sip_profile");
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(profile)) {
</del><ins>+        if (zstr(profile)) {
</ins><span class="cx">                 profile = "default";
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmoddialplansmod_dialplan_xmlmod_dialplan_xmlc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/dialplans/mod_dialplan_xml/mod_dialplan_xml.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/dialplans/mod_dialplan_xml/mod_dialplan_xml.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/dialplans/mod_dialplan_xml/mod_dialplan_xml.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -295,7 +295,7 @@
</span><span class="cx">                                 const char *inline_ = switch_xml_attr_soft(xaction, "inline");
</span><span class="cx">                                 int xinline = switch_true(inline_);
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(xaction->txt)) {
</del><ins>+                                if (!zstr(xaction->txt)) {
</ins><span class="cx">                                         data = xaction->txt;
</span><span class="cx">                                 } else {
</span><span class="cx">                                         data = (char *) switch_xml_attr_soft(xaction, "data");
</span><span class="lines">@@ -393,7 +393,7 @@
</span><span class="cx">
</span><span class="cx">         /* get our handle to the "dialplan" section of the config */
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(alt_path)) {
</del><ins>+        if (!zstr(alt_path)) {
</ins><span class="cx">                 switch_xml_t conf = NULL, tag = NULL;
</span><span class="cx">                 if (!(alt_root = switch_xml_parse_file_simple(alt_path))) {
</span><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Open of [%s] failed\n", alt_path);
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_alsamod_alsac"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_alsa/mod_alsa.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_alsa/mod_alsa.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_alsa/mod_alsa.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -366,7 +366,7 @@
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.pvt_lock);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(tech_pvt->call_id)) {
</del><ins>+        if (zstr(tech_pvt->call_id)) {
</ins><span class="cx">                 snprintf(tech_pvt->call_id, sizeof(tech_pvt->call_id), "%d", ++globals.call_id);
</span><span class="cx">                 switch_core_hash_insert(globals.call_hash, tech_pvt->call_id, tech_pvt);
</span><span class="cx">                 switch_core_session_set_read_codec(tech_pvt->session, &globals.read_codec);
</span><span class="lines">@@ -785,7 +785,7 @@
</span><span class="cx">
</span><span class="cx">                 if (outbound_profile) {
</span><span class="cx">                         char name[128];
</span><del>-                        const char *id = !switch_strlen_zero(outbound_profile->caller_id_number) ? outbound_profile->caller_id_number : "na";
</del><ins>+                        const char *id = !zstr(outbound_profile->caller_id_number) ? outbound_profile->caller_id_number : "na";
</ins><span class="cx">                         snprintf(name, sizeof(name), "alsa/%s", id);
</span><span class="cx">
</span><span class="cx">                         switch_channel_set_name(channel, name);
</span><span class="lines">@@ -1186,7 +1186,7 @@
</span><span class="cx">         char *dtmf_str = argv[0];
</span><span class="cx">         switch_dtmf_t dtmf = { 0, switch_core_default_dtmf_duration(0) };
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(dtmf_str)) {
</del><ins>+        if (zstr(dtmf_str)) {
</ins><span class="cx">                 stream->write_function(stream, "No DTMF Supplied!\n");
</span><span class="cx">         } else {
</span><span class="cx">                 switch_mutex_lock(globals.pvt_lock);
</span><span class="lines">@@ -1212,7 +1212,7 @@
</span><span class="cx">         uint8_t one_call = 0;
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.pvt_lock);
</span><del>-        if (switch_strlen_zero(callid)) {
</del><ins>+        if (zstr(callid)) {
</ins><span class="cx">                 if (globals.call_list) {
</span><span class="cx">                         if (globals.call_list->next) {
</span><span class="cx">                                 tech_pvt = globals.call_list->next;
</span><span class="lines">@@ -1258,7 +1258,7 @@
</span><span class="cx">         char *callid = argv[0];
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.pvt_lock);
</span><del>-        if (switch_strlen_zero(callid)) {
</del><ins>+        if (zstr(callid)) {
</ins><span class="cx">                 tech_pvt = globals.call_list;
</span><span class="cx">         } else {
</span><span class="cx">                 tech_pvt = switch_core_hash_find(globals.call_hash, callid);
</span><span class="lines">@@ -1285,7 +1285,7 @@
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.pvt_lock);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(callid)) {
</del><ins>+        if (!zstr(callid)) {
</ins><span class="cx">                 if ((tp = switch_core_hash_find(globals.call_hash, callid))) {
</span><span class="cx">                         if (switch_test_flag(tp, TFLAG_ANSWER)) {
</span><span class="cx">                                 stream->write_function(stream, "CALL ALREADY ANSWERED\n");
</span><span class="lines">@@ -1458,23 +1458,23 @@
</span><span class="cx">                         return SWITCH_STATUS_MEMERR;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[1])) {
</del><ins>+                if (!zstr(argv[1])) {
</ins><span class="cx">                         dialplan = argv[1];
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[2])) {
</del><ins>+                if (!zstr(argv[2])) {
</ins><span class="cx">                         cid_num = argv[2];
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[3])) {
</del><ins>+                if (!zstr(argv[3])) {
</ins><span class="cx">                         cid_name = argv[3];
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[4])) {
</del><ins>+                if (!zstr(argv[4])) {
</ins><span class="cx">                         tech_pvt->sample_rate = atoi(argv[4]);
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[5])) {
</del><ins>+                if (!zstr(argv[5])) {
</ins><span class="cx">                         tech_pvt->codec_ms = atoi(argv[5]);
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -1576,13 +1576,13 @@
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(cmd)) {
</del><ins>+                if (zstr(cmd)) {
</ins><span class="cx">                         goto done;
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="cx">         } else {
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(cmd)) {
</del><ins>+                if (zstr(cmd)) {
</ins><span class="cx">                         stream->write_function(stream, "%s", usage_string);
</span><span class="cx">                         goto done;
</span><span class="cx">                 }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_dingalingmod_dingalingc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_dingaling/mod_dingaling.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_dingaling/mod_dingaling.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_dingaling/mod_dingaling.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -344,7 +344,7 @@
</span><span class="cx">         char *status = argv[4];
</span><span class="cx">         //char *proto = argv[5];
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(type)) {
</del><ins>+        if (zstr(type)) {
</ins><span class="cx">                 type = NULL;
</span><span class="cx">         } else if (!strcasecmp(type, "unavailable")) {
</span><span class="cx">                 status = NULL;
</span><span class="lines">@@ -550,7 +550,7 @@
</span><span class="cx">                 status = NULL;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(event_type)) {
</del><ins>+        if (zstr(event_type)) {
</ins><span class="cx">                 event_type = "presence";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1993,7 +1993,7 @@
</span><span class="cx">                 profile->password = switch_core_strdup(module_pool, val);
</span><span class="cx">         } else if (!strcasecmp(var, "avatar")) {
</span><span class="cx">                 profile->avatar = switch_core_strdup(module_pool, val);
</span><del>-        } else if (!strcasecmp(var, "odbc-dsn") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "odbc-dsn") && !zstr(val)) {
</ins><span class="cx">                 if (switch_odbc_available()) {
</span><span class="cx">                         profile->odbc_dsn = switch_core_strdup(module_pool, val);
</span><span class="cx">                         if ((profile->odbc_user = strchr(profile->odbc_dsn, ':'))) {
</span><span class="lines">@@ -2007,17 +2007,17 @@
</span><span class="cx">                 }
</span><span class="cx">         } else if (!strcasecmp(var, "use-rtp-timer") && switch_true(val)) {
</span><span class="cx">                 switch_set_flag(profile, TFLAG_TIMER);
</span><del>-        } else if (!strcasecmp(var, "dialplan") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "dialplan") && !zstr(val)) {
</ins><span class="cx">                 profile->dialplan = switch_core_strdup(module_pool, val);
</span><span class="cx"> #ifdef AUTO_REPLY                                // gotta fix looping on this
</span><span class="cx">         } else if (!strcasecmp(var, "auto-reply")) {
</span><span class="cx">                 profile->auto_reply = switch_core_strdup(module_pool, val);
</span><span class="cx"> #endif
</span><del>-        } else if (!strcasecmp(var, "name") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "name") && !zstr(val)) {
</ins><span class="cx">                 profile->name = switch_core_strdup(module_pool, val);
</span><del>-        } else if (!strcasecmp(var, "message") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "message") && !zstr(val)) {
</ins><span class="cx">                 profile->message = switch_core_strdup(module_pool, val);
</span><del>-        } else if (!strcasecmp(var, "local-network-acl") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "local-network-acl") && !zstr(val)) {
</ins><span class="cx">                 profile->local_network = switch_core_strdup(module_pool, val);
</span><span class="cx">         } else if (!strcasecmp(var, "rtp-ip")) {
</span><span class="cx">                 profile->ip = switch_core_strdup(module_pool, strcasecmp(switch_str_nil(val), "auto") ? switch_str_nil(val) : globals.guess_ip);
</span><span class="lines">@@ -2030,14 +2030,14 @@
</span><span class="cx">                         ip = globals.guess_ip;
</span><span class="cx">                 } else {
</span><span class="cx">                         globals.auto_nat = 0;
</span><del>-                        ip = switch_strlen_zero(val) ? globals.guess_ip : val;
</del><ins>+                        ip = zstr(val) ? globals.guess_ip : val;
</ins><span class="cx">                 }
</span><span class="cx">                 profile->extip = switch_core_strdup(module_pool, ip);
</span><del>-        } else if (!strcasecmp(var, "server") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "server") && !zstr(val)) {
</ins><span class="cx">                 profile->server = switch_core_strdup(module_pool, val);
</span><del>-        } else if (!strcasecmp(var, "rtp-timer-name") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "rtp-timer-name") && !zstr(val)) {
</ins><span class="cx">                 profile->timer_name = switch_core_strdup(module_pool, val);
</span><del>-        } else if (!strcasecmp(var, "lanaddr") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "lanaddr") && !zstr(val)) {
</ins><span class="cx">                 profile->lanaddr = switch_core_strdup(module_pool, val);
</span><span class="cx">         } else if (!strcasecmp(var, "candidate-acl")) {
</span><span class="cx">                 if (profile->acl_count < MAX_ACL) {
</span><span class="lines">@@ -2055,11 +2055,11 @@
</span><span class="cx">                 } else if (val && !strcasecmp(val, "md5")) {
</span><span class="cx">                         profile->user_flags |= LDL_FLAG_SASL_MD5;
</span><span class="cx">                 }
</span><del>-        } else if (!strcasecmp(var, "exten") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "exten") && !zstr(val)) {
</ins><span class="cx">                 profile->exten = switch_core_strdup(module_pool, val);
</span><del>-        } else if (!strcasecmp(var, "context") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "context") && !zstr(val)) {
</ins><span class="cx">                 profile->context = switch_core_strdup(module_pool, val);
</span><del>-        } else if (!strcasecmp(var, "auto-login") && !switch_strlen_zero(val)) {
</del><ins>+        } else if (!strcasecmp(var, "auto-login") && !zstr(val)) {
</ins><span class="cx">                 if (switch_true(val)) {
</span><span class="cx">                         switch_set_flag(profile, TFLAG_AUTO);
</span><span class="cx">                 }
</span><span class="lines">@@ -2162,7 +2162,7 @@
</span><span class="cx">
</span><span class="cx">         if (session) return status;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || !(myarg = strdup(cmd))) {
</del><ins>+        if (zstr(cmd) || !(myarg = strdup(cmd))) {
</ins><span class="cx">                 stream->write_function(stream, "USAGE: %s\n", DINGALING_SYNTAX);
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="lines">@@ -2214,7 +2214,7 @@
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "USAGE: %s\n", LOGIN_SYNTAX);
</span><span class="cx">                 status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">                 goto done;
</span><span class="lines">@@ -2224,7 +2224,7 @@
</span><span class="cx">
</span><span class="cx">         argc = switch_separate_string(myarg, ';', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) || argc != 1) {
</del><ins>+        if (zstr(cmd) || argc != 1) {
</ins><span class="cx">                 stream->write_function(stream, "USAGE: %s\n", LOGIN_SYNTAX);
</span><span class="cx">                 status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">                 goto done;
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_loopbackmod_loopbackc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_loopback/mod_loopback.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_loopback/mod_loopback.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_loopback/mod_loopback.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -839,20 +839,20 @@
</span><span class="cx">                                         *dialplan++ = '\0';
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(context)) {
</del><ins>+                                if (!zstr(context)) {
</ins><span class="cx">                                         caller_profile->context = switch_core_strdup(caller_profile->pool, context);
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(dialplan)) {
</del><ins>+                                if (!zstr(dialplan)) {
</ins><span class="cx">                                         caller_profile->dialplan = switch_core_strdup(caller_profile->pool, dialplan);
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="cx">                         
</span><del>-                        if (switch_strlen_zero(caller_profile->context)) {
</del><ins>+                        if (zstr(caller_profile->context)) {
</ins><span class="cx">                                 caller_profile->context = switch_core_strdup(caller_profile->pool, "default");
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (switch_strlen_zero(caller_profile->dialplan)) {
</del><ins>+                        if (zstr(caller_profile->dialplan)) {
</ins><span class="cx">                                 caller_profile->dialplan = switch_core_strdup(caller_profile->pool, "xml");
</span><span class="cx">                         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_portaudiomod_portaudioc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_portaudio/mod_portaudio.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_portaudio/mod_portaudio.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_portaudio/mod_portaudio.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -749,7 +749,7 @@
</span><span class="cx">
</span><span class="cx">                 if (outbound_profile) {
</span><span class="cx">                         char name[128];
</span><del>-                        const char *id = !switch_strlen_zero(outbound_profile->caller_id_number) ? outbound_profile->caller_id_number : "na";
</del><ins>+                        const char *id = !zstr(outbound_profile->caller_id_number) ? outbound_profile->caller_id_number : "na";
</ins><span class="cx">                         switch_snprintf(name, sizeof(name), "portaudio/%s", id);
</span><span class="cx">
</span><span class="cx">                         switch_channel_set_name(channel, name);
</span><span class="lines">@@ -1051,7 +1051,7 @@
</span><span class="cx">                 int match = 0;
</span><span class="cx">                 pdi = Pa_GetDeviceInfo(i);
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(name)) {
</del><ins>+                if (zstr(name)) {
</ins><span class="cx">                         match = 1;
</span><span class="cx">                 } else if (pdi && pdi->name && strstr(pdi->name, name)) {
</span><span class="cx">                         match = 1;
</span><span class="lines">@@ -1476,7 +1476,7 @@
</span><span class="cx">         char *dtmf_str = argv[0];
</span><span class="cx">         switch_dtmf_t dtmf = { 0, switch_core_default_dtmf_duration(0) };
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(dtmf_str)) {
</del><ins>+        if (zstr(dtmf_str)) {
</ins><span class="cx">                 stream->write_function(stream, "No DTMF Supplied!\n");
</span><span class="cx">         } else {
</span><span class="cx">                 switch_mutex_lock(globals.pvt_lock);
</span><span class="lines">@@ -1503,7 +1503,7 @@
</span><span class="cx">         
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.pvt_lock);
</span><del>-        if (switch_strlen_zero(callid)) {
</del><ins>+        if (zstr(callid)) {
</ins><span class="cx">                 if (globals.call_list) {
</span><span class="cx">                         if (globals.call_list->next) {
</span><span class="cx">                                 tech_pvt = globals.call_list->next;
</span><span class="lines">@@ -1548,7 +1548,7 @@
</span><span class="cx">         char *callid = argv[0];
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.pvt_lock);
</span><del>-        if (switch_strlen_zero(callid)) {
</del><ins>+        if (zstr(callid)) {
</ins><span class="cx">                 tech_pvt = globals.call_list;
</span><span class="cx">         } else {
</span><span class="cx">                 tech_pvt = switch_core_hash_find(globals.call_hash, callid);
</span><span class="lines">@@ -1573,7 +1573,7 @@
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.pvt_lock);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(callid)) {
</del><ins>+        if (!zstr(callid)) {
</ins><span class="cx">                 if ((tp = switch_core_hash_find(globals.call_hash, callid))) {
</span><span class="cx">                         if (switch_test_flag(tp, TFLAG_ANSWER)) {
</span><span class="cx">                                 stream->write_function(stream, "CALL ALREADY ANSWERED\n");
</span><span class="lines">@@ -1716,7 +1716,7 @@
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">         char *dest = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(argv[0])) {
</del><ins>+        if (zstr(argv[0])) {
</ins><span class="cx">                 stream->write_function(stream, "FAIL:Usage: call <dest>\n");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -1745,23 +1745,23 @@
</span><span class="cx">                         return SWITCH_STATUS_MEMERR;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[1])) {
</del><ins>+                if (!zstr(argv[1])) {
</ins><span class="cx">                         dialplan = argv[1];
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[2])) {
</del><ins>+                if (!zstr(argv[2])) {
</ins><span class="cx">                         cid_num = argv[2];
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[3])) {
</del><ins>+                if (!zstr(argv[3])) {
</ins><span class="cx">                         cid_name = argv[3];
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[4])) {
</del><ins>+                if (!zstr(argv[4])) {
</ins><span class="cx">                         tech_pvt->sample_rate = atoi(argv[4]);
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(argv[5])) {
</del><ins>+                if (!zstr(argv[5])) {
</ins><span class="cx">                         tech_pvt->codec_ms = atoi(argv[5]);
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -1862,13 +1862,13 @@
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(cmd)) {
</del><ins>+                if (zstr(cmd)) {
</ins><span class="cx">                         goto done;
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="cx">         } else {
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(cmd)) {
</del><ins>+                if (zstr(cmd)) {
</ins><span class="cx">                         stream->write_function(stream, "%s", usage_string);
</span><span class="cx">                         goto done;
</span><span class="cx">                 }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_skypiaxmod_skypiaxc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_skypiax/mod_skypiax.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_skypiax/mod_skypiax.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_skypiax/mod_skypiax.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -866,7 +866,7 @@
</span><span class="cx">                 switch_core_session_add_stream(*new_session, NULL);
</span><span class="cx">
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(outbound_profile->destination_number)) {
</del><ins>+                if (!zstr(outbound_profile->destination_number)) {
</ins><span class="cx">                         int i;
</span><span class="cx">                         char *slash;
</span><span class="cx">
</span><span class="lines">@@ -1767,7 +1767,7 @@
</span><span class="cx">         switch_core_session_t *session = NULL;
</span><span class="cx">         switch_channel_t *channel = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(tech_pvt->session_uuid_str)) {
</del><ins>+        if (!zstr(tech_pvt->session_uuid_str)) {
</ins><span class="cx">                 session = switch_core_session_locate(tech_pvt->session_uuid_str);
</span><span class="cx">         } else {
</span><span class="cx">                 ERRORA("No session???\n", SKYPIAX_P_LOG);
</span><span class="lines">@@ -1797,7 +1797,7 @@
</span><span class="cx">         switch_core_session_t *session = NULL;
</span><span class="cx">         switch_channel_t *channel = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(tech_pvt->session_uuid_str)) {
</del><ins>+        if (!zstr(tech_pvt->session_uuid_str)) {
</ins><span class="cx">                 session = switch_core_session_locate(tech_pvt->session_uuid_str);
</span><span class="cx">         } else {
</span><span class="cx">                 ERRORA("No session???\n\n\n", SKYPIAX_P_LOG);
</span><span class="lines">@@ -1831,7 +1831,7 @@
</span><span class="cx">         switch_core_session_t *session = NULL;
</span><span class="cx">         switch_channel_t *channel = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(tech_pvt->session_uuid_str)) {
</del><ins>+        if (!zstr(tech_pvt->session_uuid_str)) {
</ins><span class="cx">                 session = switch_core_session_locate(tech_pvt->session_uuid_str);
</span><span class="cx">         } else {
</span><span class="cx">                 ERRORA("No session???\n", SKYPIAX_P_LOG);
</span><span class="lines">@@ -1917,7 +1917,7 @@
</span><span class="cx">         else
</span><span class="cx">                 stream->write_function(stream, "sk console is NOT yet assigned\n");
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2031,7 +2031,7 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">         private_t *tech_pvt = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2280,7 +2280,7 @@
</span><span class="cx">
</span><span class="cx">         DEBUGA_SKYPE("received CHATMESSAGE on interface %s\n", SKYPIAX_P_LOG, tech_pvt->name);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(tech_pvt->session_uuid_str)) {
</del><ins>+        if (!zstr(tech_pvt->session_uuid_str)) {
</ins><span class="cx">                 session = switch_core_session_locate(tech_pvt->session_uuid_str);
</span><span class="cx">         }
</span><span class="cx">         if (switch_event_create(&event, SWITCH_EVENT_MESSAGE) == SWITCH_STATUS_SUCCESS) {
</span><span class="lines">@@ -2348,7 +2348,7 @@
</span><span class="cx">         int found = 0;
</span><span class="cx">         //char skype_msg[1024];
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
</del><ins>+        if (!zstr(cmd) && (mycmd = strdup(cmd))) {
</ins><span class="cx">                 argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_sofiamod_sofiac"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/mod_sofia.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_sofia/mod_sofia.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/mod_sofia.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -88,7 +88,7 @@
</span><span class="cx">         if (sofia_test_flag(tech_pvt, TFLAG_OUTBOUND)) {
</span><span class="cx">                 const char *var;
</span><span class="cx">
</span><del>-                if ((var = switch_channel_get_variable(channel, SOFIA_SECURE_MEDIA_VARIABLE)) && !switch_strlen_zero(var)) {
</del><ins>+                if ((var = switch_channel_get_variable(channel, SOFIA_SECURE_MEDIA_VARIABLE)) && !zstr(var)) {
</ins><span class="cx">                         if (switch_true(var) || !strcasecmp(var, SWITCH_RTP_CRYPTO_KEY_32)) {
</span><span class="cx">                                 sofia_set_flag_locked(tech_pvt, TFLAG_SECURE);
</span><span class="cx">                                 sofia_glue_build_crypto(tech_pvt, 1, AES_CM_128_HMAC_SHA1_32, SWITCH_RTP_CRYPTO_SEND);
</span><span class="lines">@@ -185,17 +185,17 @@
</span><span class="cx">                 callee_name = switch_channel_get_variable(tech_pvt->channel, "callee_id_name");
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero((callee_number = switch_channel_get_variable(tech_pvt->channel, "sip_callee_id_number")))) {
-                if (switch_strlen_zero((callee_number = switch_channel_get_variable(tech_pvt->channel, "callee_id_number")))) {
</del><ins>+        if (zstr((callee_number = switch_channel_get_variable(tech_pvt->channel, "sip_callee_id_number")))) {
+                if (zstr((callee_number = switch_channel_get_variable(tech_pvt->channel, "callee_id_number")))) {
</ins><span class="cx">                         callee_number = tech_pvt->caller_profile->destination_number;
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(callee_name) && !switch_strlen_zero(callee_number)) {
</del><ins>+        if (zstr(callee_name) && !zstr(callee_number)) {
</ins><span class="cx">                 callee_name = callee_number;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(callee_name) && !switch_strlen_zero(callee_number)) {
</del><ins>+        if (!zstr(callee_name) && !zstr(callee_number)) {
</ins><span class="cx">                 pai = switch_core_session_sprintf(tech_pvt->session, "P-Asserted-Identity: \"%s\" <%s>\nX-FS-Display-Name: %s\nX-FS-Display-Number: %s\n",
</span><span class="cx">                                                                                  callee_name, callee_number, callee_name, callee_number);
</span><span class="cx">         }
</span><span class="lines">@@ -312,7 +312,7 @@
</span><span class="cx">                 ps_cause = switch_channel_get_variable(channel, SWITCH_PROTO_SPECIFIC_HANGUP_CAUSE_VARIABLE);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(ps_cause) && (!strncasecmp(ps_cause, "sip:", 4) || !strncasecmp(ps_cause, "sips:", 5))) {
</del><ins>+        if (!zstr(ps_cause) && (!strncasecmp(ps_cause, "sip:", 4) || !strncasecmp(ps_cause, "sips:", 5))) {
</ins><span class="cx">                 int new_cause = atoi(sofia_glue_strip_proto(ps_cause));
</span><span class="cx">                 if (new_cause) {
</span><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "%s Overriding SIP cause %d with %d from the other leg\n",
</span><span class="lines">@@ -389,8 +389,8 @@
</span><span class="cx">                         if (!sofia_test_flag(tech_pvt, TFLAG_BYE)) {
</span><span class="cx">                                 nua_bye(tech_pvt->nh,
</span><span class="cx">                                                 SIPTAG_REASON_STR(reason),
</span><del>-                                                TAG_IF(!switch_strlen_zero(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
-                                                TAG_IF(!switch_strlen_zero(bye_headers), SIPTAG_HEADER_STR(bye_headers)),
</del><ins>+                                                TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
+                                                TAG_IF(!zstr(bye_headers), SIPTAG_HEADER_STR(bye_headers)),
</ins><span class="cx">                                                 TAG_END());
</span><span class="cx">                         }
</span><span class="cx">                 } else {
</span><span class="lines">@@ -402,7 +402,7 @@
</span><span class="cx">                                 if (!sofia_test_flag(tech_pvt, TFLAG_BYE)) {
</span><span class="cx">                                         nua_cancel(tech_pvt->nh,
</span><span class="cx">                                                          SIPTAG_REASON_STR(reason),
</span><del>-                                                         TAG_IF(!switch_strlen_zero(bye_headers), SIPTAG_HEADER_STR(bye_headers)),
</del><ins>+                                                         TAG_IF(!zstr(bye_headers), SIPTAG_HEADER_STR(bye_headers)),
</ins><span class="cx">                                                          TAG_END());
</span><span class="cx">                                 }
</span><span class="cx">                         } else {
</span><span class="lines">@@ -413,7 +413,7 @@
</span><span class="cx">                                 if (!sofia_test_flag(tech_pvt, TFLAG_BYE)) {
</span><span class="cx">                                         nua_respond(tech_pvt->nh, sip_cause, sip_status_phrase(sip_cause),
</span><span class="cx">                                                                 SIPTAG_REASON_STR(reason),
</span><del>-                                                                TAG_IF(!switch_strlen_zero(bye_headers), SIPTAG_HEADER_STR(bye_headers)),
</del><ins>+                                                                TAG_IF(!zstr(bye_headers), SIPTAG_HEADER_STR(bye_headers)),
</ins><span class="cx">                                                                 TAG_END());
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="lines">@@ -488,7 +488,7 @@
</span><span class="cx">                                                         SOATAG_USER_SDP_STR(tech_pvt->local_sdp_str),
</span><span class="cx">                                                         SOATAG_REUSE_REJECTED(1),
</span><span class="cx">                                                         SOATAG_ORDERED_USER(1), SOATAG_AUDIO_AUX("cn telephone-event"), NUTAG_INCLUDE_EXTRA_SDP(1),
</span><del>-                                                        TAG_IF(!switch_strlen_zero(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
</del><ins>+                                                        TAG_IF(!zstr(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
</ins><span class="cx">                                                         SIPTAG_HEADER_STR("X-FS-Support: "FREESWITCH_SUPPORT),
</span><span class="cx">                                                         TAG_END());
</span><span class="cx">
</span><span class="lines">@@ -577,7 +577,7 @@
</span><span class="cx">                                         SIPTAG_CALL_INFO_STR(switch_channel_get_variable(tech_pvt->channel, SOFIA_SIP_HEADER_PREFIX "call_info")),
</span><span class="cx">                                         SOATAG_USER_SDP_STR(tech_pvt->local_sdp_str),
</span><span class="cx">                                         SOATAG_REUSE_REJECTED(1), SOATAG_ORDERED_USER(1), SOATAG_AUDIO_AUX("cn telephone-event"), NUTAG_INCLUDE_EXTRA_SDP(1),
</span><del>-                                        TAG_IF(!switch_strlen_zero(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
</del><ins>+                                        TAG_IF(!zstr(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
</ins><span class="cx">                                         SIPTAG_HEADER_STR("X-FS-Support: "FREESWITCH_SUPPORT),
</span><span class="cx">                                         TAG_END());
</span><span class="cx">                 switch_safe_free(extra_headers);
</span><span class="lines">@@ -1276,7 +1276,7 @@
</span><span class="cx">                         char *argv[2] = { 0 };
</span><span class="cx">                         int argc;
</span><span class="cx">                         
</span><del>-                        if (switch_strlen_zero(name) && !switch_strlen_zero(msg->string_arg)) {
</del><ins>+                        if (zstr(name) && !zstr(msg->string_arg)) {
</ins><span class="cx">                                 arg = strdup(msg->string_arg);
</span><span class="cx">                                 switch_assert(arg);
</span><span class="cx">
</span><span class="lines">@@ -1286,37 +1286,37 @@
</span><span class="cx">
</span><span class="cx">                         }
</span><span class="cx">                         
</span><del>-                        if (!switch_strlen_zero(name)) {
</del><ins>+                        if (!zstr(name)) {
</ins><span class="cx">                                 char message[256] = "";
</span><span class="cx">                                 const char *ua = switch_channel_get_variable(tech_pvt->channel, "sip_user_agent");
</span><span class="cx">                                 switch_event_t *event;
</span><span class="cx">
</span><del>-                                if (switch_strlen_zero(number)) {
</del><ins>+                                if (zstr(number)) {
</ins><span class="cx">                                         number = tech_pvt->caller_profile->destination_number;
</span><span class="cx">                                 }
</span><span class="cx">
</span><span class="cx">                                 if (!sofia_test_flag(tech_pvt, TFLAG_UPDATING_DISPLAY)) {
</span><del>-                                        if (switch_strlen_zero(tech_pvt->last_sent_callee_id_name) || strcmp(tech_pvt->last_sent_callee_id_name, name) ||
-                                                switch_strlen_zero(tech_pvt->last_sent_callee_id_number) || strcmp(tech_pvt->last_sent_callee_id_number, number)) {
</del><ins>+                                        if (zstr(tech_pvt->last_sent_callee_id_name) || strcmp(tech_pvt->last_sent_callee_id_name, name) ||
+                                                zstr(tech_pvt->last_sent_callee_id_number) || strcmp(tech_pvt->last_sent_callee_id_number, number)) {
</ins><span class="cx">                                                 
</span><span class="cx">                                                 if (switch_stristr("update_display", tech_pvt->x_freeswitch_support_remote)) {
</span><span class="cx">                                                         snprintf(message, sizeof(message), "X-FS-Display-Name: %s\nX-FS-Display-Number: %s\n", name, number);
</span><span class="cx">
</span><span class="cx">                                                         nua_info(tech_pvt->nh, SIPTAG_CONTENT_TYPE_STR("message/update_display"),
</span><del>-                                                                         TAG_IF(!switch_strlen_zero_buf(message), SIPTAG_HEADER_STR(message)),
-                                                                         TAG_IF(!switch_strlen_zero(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</del><ins>+                                                                         TAG_IF(!zstr_buf(message), SIPTAG_HEADER_STR(message)),
+                                                                         TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</ins><span class="cx">                                                                          TAG_END());
</span><span class="cx">                                                 } else if (ua && switch_stristr("snom", ua)) {
</span><span class="cx">                                                         snprintf(message, sizeof(message), "From:\r\nTo: \"%s\" %s\r\n", name, number);
</span><span class="cx">                                                         nua_info(tech_pvt->nh, SIPTAG_CONTENT_TYPE_STR("message/sipfrag"),
</span><del>-                                                                         TAG_IF(!switch_strlen_zero(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</del><ins>+                                                                         TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</ins><span class="cx">                                                                          SIPTAG_PAYLOAD_STR(message), TAG_END());
</span><span class="cx">                                                 } else if ((ua && (switch_stristr("polycom", ua)))) {
</span><span class="cx">                                                         snprintf(message, sizeof(message), "P-Asserted-Identity: \"%s\" <%s>", name, number);
</span><span class="cx">                                                         sofia_set_flag_locked(tech_pvt, TFLAG_UPDATING_DISPLAY);
</span><span class="cx">                                                         nua_update(tech_pvt->nh,
</span><del>-                                                                         TAG_IF(!switch_strlen_zero_buf(message), SIPTAG_HEADER_STR(message)),
-                                                                         TAG_IF(!switch_strlen_zero(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</del><ins>+                                                                         TAG_IF(!zstr_buf(message), SIPTAG_HEADER_STR(message)),
+                                                                         TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</ins><span class="cx">                                                                          TAG_END());
</span><span class="cx">                                                 }
</span><span class="cx">
</span><span class="lines">@@ -1348,20 +1348,20 @@
</span><span class="cx">                 {
</span><span class="cx">                         sofia_set_flag_locked(tech_pvt, TFLAG_SIP_HOLD);
</span><span class="cx">                         sofia_glue_do_invite(session);
</span><del>-                        if (!switch_strlen_zero(msg->string_arg)) {
</del><ins>+                        if (!zstr(msg->string_arg)) {
</ins><span class="cx">                                 char message[256] = "";
</span><span class="cx">                                 const char *ua = switch_channel_get_variable(tech_pvt->channel, "sip_user_agent");
</span><span class="cx">
</span><span class="cx">                                 if (ua && switch_stristr("snom", ua)) {
</span><span class="cx">                                         snprintf(message, sizeof(message), "From:\r\nTo: \"%s\" %s\r\n", msg->string_arg, tech_pvt->caller_profile->destination_number);
</span><span class="cx">                                         nua_info(tech_pvt->nh, SIPTAG_CONTENT_TYPE_STR("message/sipfrag"),
</span><del>-                                                         TAG_IF(!switch_strlen_zero(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</del><ins>+                                                         TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</ins><span class="cx">                                                          SIPTAG_PAYLOAD_STR(message), TAG_END());
</span><span class="cx">                                 } else if (ua && switch_stristr("polycom", ua)) {
</span><span class="cx">                                         snprintf(message, sizeof(message), "P-Asserted-Identity: \"%s\" <%s>", msg->string_arg, tech_pvt->caller_profile->destination_number);
</span><span class="cx">                                         nua_update(tech_pvt->nh,
</span><del>-                                                         TAG_IF(!switch_strlen_zero_buf(message), SIPTAG_HEADER_STR(message)),
-                                                         TAG_IF(!switch_strlen_zero(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</del><ins>+                                                         TAG_IF(!zstr_buf(message), SIPTAG_HEADER_STR(message)),
+                                                         TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</ins><span class="cx">                                                          TAG_END());
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="lines">@@ -1375,7 +1375,7 @@
</span><span class="cx">                 }
</span><span class="cx">                 break;
</span><span class="cx">         case SWITCH_MESSAGE_INDICATE_REDIRECT:
</span><del>-                if (!switch_strlen_zero(msg->string_arg)) {
</del><ins>+                if (!zstr(msg->string_arg)) {
</ins><span class="cx">                         if (!switch_channel_test_flag(channel, CF_ANSWERED) && !sofia_test_flag(tech_pvt, TFLAG_BYE)) {
</span><span class="cx">                                 char *dest = (char *) msg->string_arg;
</span><span class="cx">
</span><span class="lines">@@ -1423,7 +1423,7 @@
</span><span class="cx">                         if (code) {
</span><span class="cx">                                 reason = msg->string_arg;
</span><span class="cx">                         } else {
</span><del>-                                if (!switch_strlen_zero(msg->string_arg)) {
</del><ins>+                                if (!zstr(msg->string_arg)) {
</ins><span class="cx">                                         if ((code = atoi(msg->string_arg))) {
</span><span class="cx">                                                 if ((reason = strchr(msg->string_arg, ' '))) {
</span><span class="cx">                                                         reason++;
</span><span class="lines">@@ -1442,9 +1442,9 @@
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="cx">                         
</span><del>-                        if (switch_strlen_zero(reason) && code != 407 && code != 302) {
</del><ins>+                        if (zstr(reason) && code != 407 && code != 302) {
</ins><span class="cx">                                 reason = sip_status_phrase(code);
</span><del>-                                if (switch_strlen_zero(reason)) {
</del><ins>+                                if (zstr(reason)) {
</ins><span class="cx">                                         reason = "Because";
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="lines">@@ -1455,7 +1455,7 @@
</span><span class="cx">                                 const char *to_uri = switch_channel_get_variable(channel, "sip_to_uri");
</span><span class="cx">                                 const char *to_host = reason;
</span><span class="cx">
</span><del>-                                if (switch_strlen_zero(to_host)) {
</del><ins>+                                if (zstr(to_host)) {
</ins><span class="cx">                                         to_host = switch_channel_get_variable(channel, "sip_to_host");
</span><span class="cx">                                 }
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Challenging call %s\n", to_uri);
</span><span class="lines">@@ -1479,12 +1479,12 @@
</span><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Overlap Dial with %d %s\n", code, reason);
</span><span class="cx">                                         nua_respond(tech_pvt->nh, code, su_strdup(nua_handle_home(tech_pvt->nh), reason), TAG_IF(to_uri, SIPTAG_CONTACT_STR(to_uri)),
</span><span class="cx">                                                                 SIPTAG_SUPPORTED_STR(NULL), SIPTAG_ACCEPT_STR(NULL),
</span><del>-                                                                TAG_IF(!switch_strlen_zero(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
-                                                                TAG_IF(!switch_strlen_zero(max_forwards), SIPTAG_MAX_FORWARDS_STR(max_forwards)), TAG_END());
</del><ins>+                                                                TAG_IF(!zstr(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
+                                                                TAG_IF(!zstr(max_forwards), SIPTAG_MAX_FORWARDS_STR(max_forwards)), TAG_END());
</ins><span class="cx">                                         
</span><span class="cx">                                         sofia_set_flag_locked(tech_pvt, TFLAG_BYE);
</span><span class="cx">                                 }
</span><del>-                        } else if (code == 302 && !switch_strlen_zero(msg->string_arg)) {
</del><ins>+                        } else if (code == 302 && !zstr(msg->string_arg)) {
</ins><span class="cx">                                 char *p;
</span><span class="cx">
</span><span class="cx">                                 if ((p = strchr(msg->string_arg, ' '))) {
</span><span class="lines">@@ -1498,7 +1498,7 @@
</span><span class="cx">                         } else {
</span><span class="cx">                                 if (!sofia_test_flag(tech_pvt, TFLAG_BYE)) {
</span><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Responding with %d [%s]\n", code, reason);
</span><del>-                                        if (!switch_strlen_zero(((char *) msg->pointer_arg))) {
</del><ins>+                                        if (!zstr(((char *) msg->pointer_arg))) {
</ins><span class="cx">                                                 sofia_glue_tech_set_local_sdp(tech_pvt, (char *) msg->pointer_arg, SWITCH_TRUE);
</span><span class="cx">                                                 
</span><span class="cx">                                                 if (switch_channel_test_flag(channel, CF_PROXY_MEDIA)) {
</span><span class="lines">@@ -1509,11 +1509,11 @@
</span><span class="cx">                                                                         SOATAG_USER_SDP_STR(tech_pvt->local_sdp_str),
</span><span class="cx">                                                                         SOATAG_REUSE_REJECTED(1),
</span><span class="cx">                                                                         SOATAG_ORDERED_USER(1), SOATAG_AUDIO_AUX("cn telephone-event"), NUTAG_INCLUDE_EXTRA_SDP(1),
</span><del>-                                                                        TAG_IF(!switch_strlen_zero(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
</del><ins>+                                                                        TAG_IF(!zstr(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
</ins><span class="cx">                                                                         TAG_END());
</span><span class="cx">                                         } else {
</span><span class="cx">                                                 nua_respond(tech_pvt->nh, code, su_strdup(nua_handle_home(tech_pvt->nh), reason), SIPTAG_CONTACT_STR(tech_pvt->reply_contact),
</span><del>-                                                                        TAG_IF(!switch_strlen_zero(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
</del><ins>+                                                                        TAG_IF(!zstr(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
</ins><span class="cx">                                                                         TAG_END());
</span><span class="cx">                                         }
</span><span class="cx">                                 }
</span><span class="lines">@@ -1528,7 +1528,7 @@
</span><span class="cx">                         nua_respond(tech_pvt->nh, SIP_180_RINGING,
</span><span class="cx">                                                 SIPTAG_CONTACT_STR(tech_pvt->reply_contact),
</span><span class="cx">                                                 SIPTAG_HEADER_STR(generate_pai_str(session)),
</span><del>-                                                TAG_IF(!switch_strlen_zero(extra_header), SIPTAG_HEADER_STR(extra_header)),
</del><ins>+                                                TAG_IF(!zstr(extra_header), SIPTAG_HEADER_STR(extra_header)),
</ins><span class="cx">                                                 SIPTAG_HEADER_STR("X-FS-Support: "FREESWITCH_SUPPORT),
</span><span class="cx">                                                 TAG_END());
</span><span class="cx">                         switch_safe_free(extra_header);
</span><span class="lines">@@ -1614,7 +1614,7 @@
</span><span class="cx">                                                                 SOATAG_ORDERED_USER(1),
</span><span class="cx">                                                                 SOATAG_ADDRESS(tech_pvt->adv_sdp_audio_ip),
</span><span class="cx">                                                                 SOATAG_USER_SDP_STR(tech_pvt->local_sdp_str), SOATAG_AUDIO_AUX("cn telephone-event"),
</span><del>-                                                                TAG_IF(!switch_strlen_zero(extra_header), SIPTAG_HEADER_STR(extra_header)),
</del><ins>+                                                                TAG_IF(!zstr(extra_header), SIPTAG_HEADER_STR(extra_header)),
</ins><span class="cx">                                                                 SIPTAG_HEADER_STR("X-FS-Support: "FREESWITCH_SUPPORT),
</span><span class="cx">                                                                 TAG_END());
</span><span class="cx">                                         switch_safe_free(extra_header);
</span><span class="lines">@@ -1795,7 +1795,7 @@
</span><span class="cx">                                 stream->write_function(stream, "Scheme \t%s\n", switch_str_nil(gp->register_scheme));
</span><span class="cx">                                 stream->write_function(stream, "Realm \t%s\n", switch_str_nil(gp->register_realm));
</span><span class="cx">                                 stream->write_function(stream, "Username\t%s\n", switch_str_nil(gp->register_username));
</span><del>-                                stream->write_function(stream, "Password\t%s\n", switch_strlen_zero(gp->register_password) ? "no" : "yes");
</del><ins>+                                stream->write_function(stream, "Password\t%s\n", zstr(gp->register_password) ? "no" : "yes");
</ins><span class="cx">                                 stream->write_function(stream, "From \t%s\n", switch_str_nil(gp->register_from));
</span><span class="cx">                                 stream->write_function(stream, "Contact \t%s\n", switch_str_nil(gp->register_contact));
</span><span class="cx">                                 stream->write_function(stream, "Exten \t%s\n", switch_str_nil(gp->extension));
</span><span class="lines">@@ -1832,7 +1832,7 @@
</span><span class="cx">                                         stream->write_function(stream, "Dialplan \t%s\n", switch_str_nil(profile->dialplan));
</span><span class="cx">                                         stream->write_function(stream, "Context \t%s\n", switch_str_nil(profile->context));
</span><span class="cx">                                         stream->write_function(stream, "Challenge Realm \t%s\n",
</span><del>-                                                                                 switch_strlen_zero(profile->challenge_realm) ? "auto_to" : profile->challenge_realm);
</del><ins>+                                                                                 zstr(profile->challenge_realm) ? "auto_to" : profile->challenge_realm);
</ins><span class="cx">                                         stream->write_function(stream, "RTP-IP \t%s\n", switch_str_nil(profile->rtpip));
</span><span class="cx">                                         if (profile->extrtpip) {
</span><span class="cx">                                         stream->write_function(stream, "Ext-RTP-IP \t%s\n", profile->extrtpip);
</span><span class="lines">@@ -1848,8 +1848,8 @@
</span><span class="cx">                                         stream->write_function(stream, "TLS-URL \t%s\n", switch_str_nil(profile->tls_url));
</span><span class="cx">                                         stream->write_function(stream, "TLS-BIND-URL \t%s\n", switch_str_nil(profile->tls_bindurl));
</span><span class="cx">                                         }
</span><del>-                                        stream->write_function(stream, "HOLD-MUSIC \t%s\n", switch_strlen_zero(profile->hold_music) ? "N/A" : profile->hold_music);
-                                        stream->write_function(stream, "OUTBOUND-PROXY \t%s\n", switch_strlen_zero(profile->outbound_proxy) ? "N/A" : profile->outbound_proxy);
</del><ins>+                                        stream->write_function(stream, "HOLD-MUSIC \t%s\n", zstr(profile->hold_music) ? "N/A" : profile->hold_music);
+                                        stream->write_function(stream, "OUTBOUND-PROXY \t%s\n", zstr(profile->outbound_proxy) ? "N/A" : profile->outbound_proxy);
</ins><span class="cx">                                         stream->write_function(stream, "CODECS \t%s\n", switch_str_nil(profile->codec_string));
</span><span class="cx">                                         stream->write_function(stream, "TEL-EVENT \t%d\n", profile->te);
</span><span class="cx">                                         if (profile->dtmf_type == DTMF_2833) {
</span><span class="lines">@@ -1906,9 +1906,9 @@
</span><span class="cx">                                                 host = dup;
</span><span class="cx">                                         }
</span><span class="cx">
</span><del>-                                        if (switch_strlen_zero(user) ) {
</del><ins>+                                        if (zstr(user) ) {
</ins><span class="cx">                                                 sqlextra = switch_mprintf("(sip_host='%q')", host);
</span><del>-                                        } else if (switch_strlen_zero(host)) {
</del><ins>+                                        } else if (zstr(host)) {
</ins><span class="cx">                                                 sqlextra = switch_mprintf("(sip_user='%q')", user);
</span><span class="cx">                                         } else {
</span><span class="cx">                                                 sqlextra = switch_mprintf("(sip_user='%q' and sip_host='%q')", user, host);
</span><span class="lines">@@ -2019,7 +2019,7 @@
</span><span class="cx">                                 stream->write_function(stream, " <scheme>%s</scheme>\n", switch_str_nil(gp->register_scheme));
</span><span class="cx">                                 stream->write_function(stream, " <realm>%s</realm>\n", switch_str_nil(gp->register_realm));
</span><span class="cx">                                 stream->write_function(stream, " <username>%s</username>\n", switch_str_nil(gp->register_username));
</span><del>-                                stream->write_function(stream, " <password>%s</password>\n", switch_strlen_zero(gp->register_password) ? "no" : "yes");
</del><ins>+                                stream->write_function(stream, " <password>%s</password>\n", zstr(gp->register_password) ? "no" : "yes");
</ins><span class="cx">                                 stream->write_function(stream, " <from>%s</from>\n", switch_amp_encode(switch_str_nil(gp->register_from),xmlbuf,buflen));
</span><span class="cx">                                 stream->write_function(stream, " <contact>%s</contact>\n", switch_amp_encode(switch_str_nil(gp->register_contact),xmlbuf,buflen));
</span><span class="cx">                                 stream->write_function(stream, " <exten>%s</exten>\n", switch_amp_encode(switch_str_nil(gp->extension),xmlbuf,buflen));
</span><span class="lines">@@ -2059,7 +2059,7 @@
</span><span class="cx">                                         stream->write_function(stream, " <dialplan>%s</dialplan>\n", switch_str_nil(profile->dialplan));
</span><span class="cx">                                         stream->write_function(stream, " <context>%s</context>\n", switch_str_nil(profile->context));
</span><span class="cx">                                         stream->write_function(stream, " <challenge-realm>%s</challenge-realm>\n",
</span><del>-                                                                                 switch_strlen_zero(profile->challenge_realm) ? "auto_to" : profile->challenge_realm);
</del><ins>+                                                                                 zstr(profile->challenge_realm) ? "auto_to" : profile->challenge_realm);
</ins><span class="cx">                                         stream->write_function(stream, " <rtp-ip>%s</rtp-ip>\n", switch_str_nil(profile->rtpip));
</span><span class="cx">                                         stream->write_function(stream, " <ext-rtp-ip>%s</ext-rtp-ip>\n", profile->extrtpip);
</span><span class="cx">                                         stream->write_function(stream, " <sip-ip>%s</sip-ip>\n", switch_str_nil(profile->sipip));
</span><span class="lines">@@ -2068,8 +2068,8 @@
</span><span class="cx">                                         stream->write_function(stream, " <bind-url>%s</bind-url>\n", switch_str_nil(profile->bindurl));
</span><span class="cx">                                         stream->write_function(stream, " <tls-url>%s</tls-url>\n", switch_str_nil(profile->tls_url));
</span><span class="cx">                                         stream->write_function(stream, " <tls-bind-url>%s</tls-bind-url>\n", switch_str_nil(profile->tls_bindurl));
</span><del>-                                        stream->write_function(stream, " <hold-music>%s</hold-music>\n", switch_strlen_zero(profile->hold_music) ? "N/A" : profile->hold_music);
-                                        stream->write_function(stream, " <outbound-proxy>%s</outbound-proxy>\n", switch_strlen_zero(profile->outbound_proxy) ? "N/A" : profile->outbound_proxy);
</del><ins>+                                        stream->write_function(stream, " <hold-music>%s</hold-music>\n", zstr(profile->hold_music) ? "N/A" : profile->hold_music);
+                                        stream->write_function(stream, " <outbound-proxy>%s</outbound-proxy>\n", zstr(profile->outbound_proxy) ? "N/A" : profile->outbound_proxy);
</ins><span class="cx">                                         stream->write_function(stream, " <codecs>%s</codecs>\n", switch_str_nil(profile->codec_string));
</span><span class="cx">                                         stream->write_function(stream, " <tel-event>%d</tel-event>\n", profile->te);
</span><span class="cx">                                         stream->write_function(stream, " <dtmf-mode>rfc2833</dtmf-mode>\n");
</span><span class="lines">@@ -2127,9 +2127,9 @@
</span><span class="cx">                                                 host = dup;
</span><span class="cx">                                         }
</span><span class="cx">
</span><del>-                                        if (switch_strlen_zero(user)) {
</del><ins>+                                        if (zstr(user)) {
</ins><span class="cx">                                                 sqlextra = switch_mprintf("(sip_host='%q')", host);
</span><del>-                                        } else if (switch_strlen_zero(host)) {
</del><ins>+                                        } else if (zstr(host)) {
</ins><span class="cx">                                                 sqlextra = switch_mprintf("(sip_user='%q')", user);
</span><span class="cx">                                         } else {
</span><span class="cx">                                                 sqlextra = switch_mprintf("(sip_user='%q' and sip_host='%q')", user, host);
</span><span class="lines">@@ -2244,7 +2244,7 @@
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(profile_name) || !(profile = sofia_glue_find_profile(profile_name))) {
</del><ins>+        if (zstr(profile_name) || !(profile = sofia_glue_find_profile(profile_name))) {
</ins><span class="cx">                 stream->write_function(stream, "Invalid Profile [%s]", switch_str_nil(profile_name));
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -2344,7 +2344,7 @@
</span><span class="cx">                 char *gname = argv[2];
</span><span class="cx">                 sofia_gateway_t *gateway_ptr;
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(gname)) {
</del><ins>+                if (zstr(gname)) {
</ins><span class="cx">                         stream->write_function(stream, "No gateway name provided!\n");
</span><span class="cx">                         goto done;
</span><span class="cx">                 }
</span><span class="lines">@@ -2371,7 +2371,7 @@
</span><span class="cx">                 char *gname = argv[2];
</span><span class="cx">                 sofia_gateway_t *gateway_ptr;
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(gname)) {
</del><ins>+                if (zstr(gname)) {
</ins><span class="cx">                         stream->write_function(stream, "No gateway name provided!\n");
</span><span class="cx">                         goto done;
</span><span class="cx">                 }
</span><span class="lines">@@ -2447,7 +2447,7 @@
</span><span class="cx">         struct cb_helper *cb = (struct cb_helper *) pArg;
</span><span class="cx">         char *contact;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(argv[0]) && (contact = sofia_glue_get_url_from_contact(argv[0], 1)) ) {
</del><ins>+        if (!zstr(argv[0]) && (contact = sofia_glue_get_url_from_contact(argv[0], 1)) ) {
</ins><span class="cx">                 cb->stream->write_function(cb->stream, "%ssofia/%s/sip:%s,", argv[2], argv[1], sofia_glue_strip_proto(contact));
</span><span class="cx">                 free(contact);
</span><span class="cx">         }
</span><span class="lines">@@ -2545,11 +2545,11 @@
</span><span class="cx">                         sofia_glue_execute_sql_callback(profile, SWITCH_FALSE, profile->ireg_mutex, sql, contact_callback, &cb);
</span><span class="cx">                         switch_safe_free(sql);
</span><span class="cx">                         reply = (char *) mystream.data;
</span><del>-                        if (!switch_strlen_zero(reply) && end_of(reply) == ',') {
</del><ins>+                        if (!zstr(reply) && end_of(reply) == ',') {
</ins><span class="cx">                                 end_of(reply) = '\0';
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (switch_strlen_zero(reply)) {
</del><ins>+                        if (zstr(reply)) {
</ins><span class="cx">                                 reply = "error/user_not_registered";
</span><span class="cx">                         }
</span><span class="cx">
</span><span class="lines">@@ -2583,7 +2583,7 @@
</span><span class="cx">         char *gwname, *param, *varname;
</span><span class="cx">         const char *val = NULL;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR Parameter missing\n");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -2599,7 +2599,7 @@
</span><span class="cx">         param = argv[1];
</span><span class="cx">         varname = argv[2];
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(gwname) || switch_strlen_zero(param) || switch_strlen_zero(varname)) {
</del><ins>+        if (zstr(gwname) || zstr(param) || zstr(varname)) {
</ins><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="cx">         
</span><span class="lines">@@ -2647,7 +2647,7 @@
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "%s", usage_string);
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -2880,11 +2880,11 @@
</span><span class="cx">                 
</span><span class="cx">                 gateway_ptr->ob_calls++;
</span><span class="cx">                 
</span><del>-                if (!switch_strlen_zero(gateway_ptr->from_domain) && !switch_channel_get_variable(nchannel, "sip_invite_domain")) {
</del><ins>+                if (!zstr(gateway_ptr->from_domain) && !switch_channel_get_variable(nchannel, "sip_invite_domain")) {
</ins><span class="cx">                         switch_channel_set_variable(nchannel, "sip_invite_domain", gateway_ptr->from_domain);
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(gateway_ptr->outbound_sticky_proxy) && !switch_channel_get_variable(nchannel, "sip_route_uri")) {
</del><ins>+                if (!zstr(gateway_ptr->outbound_sticky_proxy) && !switch_channel_get_variable(nchannel, "sip_route_uri")) {
</ins><span class="cx">                         switch_channel_set_variable(nchannel, "sip_route_uri", gateway_ptr->outbound_sticky_proxy);
</span><span class="cx">                 }
</span><span class="cx">                 
</span><span class="lines">@@ -3115,7 +3115,7 @@
</span><span class="cx">                          NUTAG_NEWSUB(1),
</span><span class="cx">                          SIPTAG_EVENT_STR(es),
</span><span class="cx">                          SIPTAG_CONTENT_TYPE_STR(ct),
</span><del>-                         TAG_IF(!switch_strlen_zero(body), SIPTAG_PAYLOAD_STR(body)),
</del><ins>+                         TAG_IF(!zstr(body), SIPTAG_PAYLOAD_STR(body)),
</ins><span class="cx">                          TAG_END());
</span><span class="cx">
</span><span class="cx">                                 
</span><span class="lines">@@ -3193,7 +3193,7 @@
</span><span class="cx">                                                          NUTAG_WITH_THIS(profile->nua),
</span><span class="cx">                                                          SIPTAG_EVENT_STR(es),
</span><span class="cx">                                                          TAG_IF(ct, SIPTAG_CONTENT_TYPE_STR(ct)),
</span><del>-                                                         TAG_IF(!switch_strlen_zero(body), SIPTAG_PAYLOAD_STR(body)),
</del><ins>+                                                         TAG_IF(!zstr(body), SIPTAG_PAYLOAD_STR(body)),
</ins><span class="cx">                                                          TAG_END());
</span><span class="cx">                                 
</span><span class="cx">                                         sofia_glue_release_profile(profile);
</span><span class="lines">@@ -3212,7 +3212,7 @@
</span><span class="cx">                                                                  NUTAG_NEWSUB(1),
</span><span class="cx">                                                                  SIPTAG_EVENT_STR(es),
</span><span class="cx">                                                                  SIPTAG_CONTENT_TYPE_STR(ct),
</span><del>-                                                                 TAG_IF(!switch_strlen_zero(body), SIPTAG_PAYLOAD_STR(body)),
</del><ins>+                                                                 TAG_IF(!zstr(body), SIPTAG_PAYLOAD_STR(body)),
</ins><span class="cx">                                                                  TAG_END());
</span><span class="cx">                                         }
</span><span class="cx">                                         switch_core_session_rwunlock(session);
</span><span class="lines">@@ -3296,7 +3296,7 @@
</span><span class="cx">                                 nua_message(nh,
</span><span class="cx">                                                         NUTAG_NEWSUB(1),
</span><span class="cx">                                                         SIPTAG_CONTENT_TYPE_STR(ct),
</span><del>-                                                        TAG_IF(!switch_strlen_zero(body), SIPTAG_PAYLOAD_STR(body)),
</del><ins>+                                                        TAG_IF(!zstr(body), SIPTAG_PAYLOAD_STR(body)),
</ins><span class="cx">                                                         TAG_END());
</span><span class="cx">
</span><span class="cx">                                 
</span><span class="lines">@@ -3392,7 +3392,7 @@
</span><span class="cx">                                          TAG_IF(ct, SIPTAG_CONTENT_TYPE_STR(ct)),
</span><span class="cx">                                          TAG_IF(alert_info, SIPTAG_ALERT_INFO_STR(alert_info)),
</span><span class="cx">                                          TAG_IF(call_info, SIPTAG_CALL_INFO_STR(call_info)),
</span><del>-                                         TAG_IF(!switch_strlen_zero(body), SIPTAG_PAYLOAD_STR(body)),
</del><ins>+                                         TAG_IF(!zstr(body), SIPTAG_PAYLOAD_STR(body)),
</ins><span class="cx">                                          TAG_END());
</span><span class="cx">
</span><span class="cx">                         if (call_id && nh) {
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_sofiamod_sofiah"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/mod_sofia.h (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_sofia/mod_sofia.h        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/mod_sofia.h        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -818,7 +818,7 @@
</span><span class="cx">
</span><span class="cx"> #define check_decode(_var, _session) do {                                                                \
</span><span class="cx">                 assert(_session);                                                                                                \
</span><del>-                if (!switch_strlen_zero(_var)) {                                                                \
</del><ins>+                if (!zstr(_var)) {                                                                \
</ins><span class="cx">                         int d = 0;                                                                                                        \
</span><span class="cx">                         char *p;                                                                                                        \
</span><span class="cx">                         if (strchr(_var, '%')) {                                                                        \
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_sofiasofiac"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -327,7 +327,7 @@
</span><span class="cx">         
</span><span class="cx">         switch_channel_hangup(channel, cause);
</span><span class="cx">         nua_respond(nh, SIP_200_OK, NUTAG_WITH_THIS(nua),
</span><del>-                TAG_IF(!switch_strlen_zero(extra_headers), SIPTAG_HEADER_STR(extra_headers)), TAG_END());
</del><ins>+                TAG_IF(!zstr(extra_headers), SIPTAG_HEADER_STR(extra_headers)), TAG_END());
</ins><span class="cx">                 
</span><span class="cx">         switch_safe_free(extra_headers);
</span><span class="cx">
</span><span class="lines">@@ -338,9 +338,9 @@
</span><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (sip->sip_user_agent && !switch_strlen_zero(sip->sip_user_agent->g_string)) {
</del><ins>+        if (sip->sip_user_agent && !zstr(sip->sip_user_agent->g_string)) {
</ins><span class="cx">                 switch_channel_set_variable(channel, "sip_user_agent", sip->sip_user_agent->g_string);
</span><del>-        } else if (sip->sip_server && !switch_strlen_zero(sip->sip_server->g_string)) {
</del><ins>+        } else if (sip->sip_server && !zstr(sip->sip_server->g_string)) {
</ins><span class="cx">                 switch_channel_set_variable(channel, "sip_user_agent", sip->sip_server->g_string);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -384,19 +384,19 @@
</span><span class="cx">         switch_caller_profile_t *caller_profile = switch_channel_get_caller_profile(channel);
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(name)) {
</del><ins>+        if (zstr(name)) {
</ins><span class="cx">                 name = caller_profile->callee_id_name;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(number)) {
</del><ins>+        if (zstr(number)) {
</ins><span class="cx">                 number = caller_profile->callee_id_number;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(name)) {
</del><ins>+        if (zstr(name)) {
</ins><span class="cx">                 name = number;
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(number)) {
</del><ins>+        if (zstr(number)) {
</ins><span class="cx">                 number = caller_profile->destination_number;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -449,7 +449,7 @@
</span><span class="cx">                         if (passerted->paid_url && passerted->paid_url->url_user) {
</span><span class="cx">                                 number = passerted->paid_url->url_user;
</span><span class="cx">                         }
</span><del>-                        if (!switch_strlen_zero(passerted->paid_display)) {
</del><ins>+                        if (!zstr(passerted->paid_display)) {
</ins><span class="cx">                                 dup = strdup(passerted->paid_display);
</span><span class="cx">                                 if (*dup == '"') {
</span><span class="cx">                                         name = dup + 1;
</span><span class="lines">@@ -539,7 +539,7 @@
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Profile %s is locked\n", gateway->profile->name);
</span><span class="cx">                                 return;
</span><span class="cx">                         }
</span><del>-                } else if (!switch_strlen_zero(sofia_private->uuid)) {
</del><ins>+                } else if (!zstr(sofia_private->uuid)) {
</ins><span class="cx">                         if ((session = switch_core_session_locate(sofia_private->uuid))) {
</span><span class="cx">                                 tech_pvt = switch_core_session_get_private(session);
</span><span class="cx">                                 channel = switch_core_session_get_channel(session);
</span><span class="lines">@@ -553,7 +553,7 @@
</span><span class="cx">
</span><span class="cx">                                 if (status >= 180 && !*sofia_private->auth_gateway_name) {
</span><span class="cx">                                         const char *gwname = switch_channel_get_variable(channel, "sip_use_gateway");
</span><del>-                                        if (!switch_strlen_zero(gwname)) {
</del><ins>+                                        if (!zstr(gwname)) {
</ins><span class="cx">                                                 switch_set_string(sofia_private->auth_gateway_name, gwname);
</span><span class="cx">                                         }
</span><span class="cx">                                 }
</span><span class="lines">@@ -1381,7 +1381,7 @@
</span><span class="cx">                 char *name = (char *) switch_xml_attr_soft(gateway_tag, "name");
</span><span class="cx">                 sofia_gateway_t *gateway;
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(name)) {
</del><ins>+                if (zstr(name)) {
</ins><span class="cx">                         name = "anonymous";
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -1545,33 +1545,33 @@
</span><span class="cx">                                 parse_gateway_subscriptions(profile, gateway, gw_subs_tag);
</span><span class="cx">                         }
</span><span class="cx">                         
</span><del>-                        if (switch_strlen_zero(realm)) {
-                                if (switch_strlen_zero(proxy)) {
</del><ins>+                        if (zstr(realm)) {
+                                if (zstr(proxy)) {
</ins><span class="cx">                                         realm = name;
</span><span class="cx">                                 } else {
</span><span class="cx">                                         realm = proxy;
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (switch_strlen_zero(username)) {
</del><ins>+                        if (zstr(username)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "ERROR: username param is REQUIRED!\n");
</span><span class="cx">                                 goto skip;
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (switch_strlen_zero(password)) {
</del><ins>+                        if (zstr(password)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "ERROR: password param is REQUIRED!\n");
</span><span class="cx">                                 goto skip;
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (switch_strlen_zero(from_user)) {
</del><ins>+                        if (zstr(from_user)) {
</ins><span class="cx">                                 from_user = username;
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (switch_strlen_zero(extension)) {
</del><ins>+                        if (zstr(extension)) {
</ins><span class="cx">                                 extension = username;
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (switch_strlen_zero(proxy)) {
</del><ins>+                        if (zstr(proxy)) {
</ins><span class="cx">                                 proxy = realm;
</span><span class="cx">                         }
</span><span class="cx">
</span><span class="lines">@@ -1580,11 +1580,11 @@
</span><span class="cx">                                 gateway->status = SOFIA_GATEWAY_UP;
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (switch_strlen_zero(auth_username)) {
</del><ins>+                        if (zstr(auth_username)) {
</ins><span class="cx">                                 auth_username = username;
</span><span class="cx">                         }
</span><span class="cx">                         
</span><del>-                        if (!switch_strlen_zero(register_proxy)) {
</del><ins>+                        if (!zstr(register_proxy)) {
</ins><span class="cx">                                 if (strncasecmp(register_proxy, "sip:", 4) && strncasecmp(register_proxy, "sips:", 5)) {
</span><span class="cx">                                         gateway->register_sticky_proxy = switch_core_sprintf(gateway->pool, "sip:%s", register_proxy);
</span><span class="cx">                                 } else {
</span><span class="lines">@@ -1592,7 +1592,7 @@
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (!switch_strlen_zero(outbound_proxy)) {
</del><ins>+                        if (!zstr(outbound_proxy)) {
</ins><span class="cx">                                 if (strncasecmp(outbound_proxy, "sip:", 4) && strncasecmp(outbound_proxy, "sips:", 5)) {
</span><span class="cx">                                         gateway->outbound_sticky_proxy = switch_core_sprintf(gateway->pool, "sip:%s", outbound_proxy);
</span><span class="cx">                                 } else {
</span><span class="lines">@@ -1631,13 +1631,13 @@
</span><span class="cx">                                 params = switch_core_sprintf(gateway->pool, ";transport=%s;gw=%s", register_transport, gateway->name);
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (!switch_strlen_zero(from_domain)) {
</del><ins>+                        if (!zstr(from_domain)) {
</ins><span class="cx">                                 gateway->from_domain = switch_core_strdup(gateway->pool, from_domain);
</span><span class="cx">                         }
</span><span class="cx">
</span><span class="cx">                         gateway->register_url = switch_core_sprintf(gateway->pool, "sip:%s", proxy);
</span><span class="cx">                         gateway->register_from = switch_core_sprintf(gateway->pool, "<sip:%s@%s;transport=%s>",
</span><del>-                                                                                                                 from_user, !switch_strlen_zero(from_domain) ? from_domain : proxy, register_transport);
</del><ins>+                                                                                                                 from_user, !zstr(from_domain) ? from_domain : proxy, register_transport);
</ins><span class="cx">
</span><span class="cx">                         sipip = contact_host ? contact_host : profile->extsipip ? profile->extsipip : profile->sipip;
</span><span class="cx">
</span><span class="lines">@@ -2157,7 +2157,7 @@
</span><span class="cx">                                         const char *parse = switch_xml_attr_soft(domain_tag, "parse");
</span><span class="cx">                                         const char *alias = switch_xml_attr_soft(domain_tag, "alias");
</span><span class="cx">
</span><del>-                                        if (!switch_strlen_zero(dname)) {
</del><ins>+                                        if (!zstr(dname)) {
</ins><span class="cx">                                                 if (!strcasecmp(dname, "all")) {
</span><span class="cx">                                                         switch_xml_t xml_root, x_domains;
</span><span class="cx">                                                         if (switch_xml_locate("directory", NULL, NULL, NULL, &xml_root, &x_domains, xml_params, SWITCH_FALSE) == SWITCH_STATUS_SUCCESS) {
</span><span class="lines">@@ -2180,7 +2180,7 @@
</span><span class="cx">                         if ((aliases_tag = switch_xml_child(xprofile, "aliases"))) {
</span><span class="cx">                                 for (alias_tag = switch_xml_child(aliases_tag, "alias"); alias_tag; alias_tag = alias_tag->next) {
</span><span class="cx">                                         char *aname = (char *) switch_xml_attr_soft(alias_tag, "name");
</span><del>-                                        if (!switch_strlen_zero(aname)) {
</del><ins>+                                        if (!zstr(aname)) {
</ins><span class="cx">                                                 
</span><span class="cx">                                                 if (sofia_glue_add_profile(switch_core_strdup(profile->pool, aname), profile) == SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding Alias [%s] for profile [%s]\n", aname, profile->name);
</span><span class="lines">@@ -2236,7 +2236,7 @@
</span><span class="cx">                 su_log_redirect(stun_log, logger, NULL);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(profile_name) && (profile = sofia_glue_find_profile(profile_name))) {
</del><ins>+        if (!zstr(profile_name) && (profile = sofia_glue_find_profile(profile_name))) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "Profile [%s] Already exists.\n", switch_str_nil(profile_name));
</span><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">                 sofia_glue_release_profile(profile);
</span><span class="lines">@@ -2342,7 +2342,7 @@
</span><span class="cx">                                                 profile->debug = atoi(val);
</span><span class="cx">                                         } else if (!strcasecmp(var, "sip-trace") && switch_true(val)) {
</span><span class="cx">                                                 sofia_set_flag(profile, TFLAG_TPORT_LOG);
</span><del>-                                        } else if (!strcasecmp(var, "odbc-dsn") && !switch_strlen_zero(val)) {
</del><ins>+                                        } else if (!strcasecmp(var, "odbc-dsn") && !zstr(val)) {
</ins><span class="cx">                                                 if (switch_odbc_available()) {
</span><span class="cx">                                                         profile->odbc_dsn = switch_core_strdup(profile->pool, val);
</span><span class="cx">                                                         if ((profile->odbc_user = strchr(profile->odbc_dsn, ':'))) {
</span><span class="lines">@@ -2467,7 +2467,7 @@
</span><span class="cx">                                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Invalid option %s for VAD\n", val);
</span><span class="cx">                                                 }
</span><span class="cx">                                         } else if (!strcasecmp(var, "ext-rtp-ip")) {
</span><del>-                                                if (!switch_strlen_zero(val)) {
</del><ins>+                                                if (!zstr(val)) {
</ins><span class="cx">                                                         char *ip = mod_sofia_globals.guess_ip;
</span><span class="cx">                                                         
</span><span class="cx">                                                         if (!strcmp(val, "0.0.0.0")) {
</span><span class="lines">@@ -2501,7 +2501,7 @@
</span><span class="cx">                                                 }
</span><span class="cx">                                                 profile->sipip = switch_core_strdup(profile->pool, ip);
</span><span class="cx">                                         } else if (!strcasecmp(var, "ext-sip-ip")) {
</span><del>-                                                if (!switch_strlen_zero(val)) {
</del><ins>+                                                if (!zstr(val)) {
</ins><span class="cx">                                                         char *ip = mod_sofia_globals.guess_ip;
</span><span class="cx">                                                         char stun_ip[50] = "";
</span><span class="cx">                                                         char *myip = stun_ip;
</span><span class="lines">@@ -3007,7 +3007,7 @@
</span><span class="cx">                                                 const char *parse = switch_xml_attr_soft(domain_tag, "parse");
</span><span class="cx">                                                 const char *alias = switch_xml_attr_soft(domain_tag, "alias");
</span><span class="cx">
</span><del>-                                                if (!switch_strlen_zero(dname)) {
</del><ins>+                                                if (!zstr(dname)) {
</ins><span class="cx">                                                         if (!strcasecmp(dname, "all")) {
</span><span class="cx">                                                                 switch_xml_t xml_root, x_domains;
</span><span class="cx">                                                                 if (switch_xml_locate("directory", NULL, NULL, NULL, &xml_root, &x_domains, xml_params, SWITCH_FALSE) == SWITCH_STATUS_SUCCESS) {
</span><span class="lines">@@ -3030,7 +3030,7 @@
</span><span class="cx">                                 if ((aliases_tag = switch_xml_child(xprofile, "aliases"))) {
</span><span class="cx">                                         for (alias_tag = switch_xml_child(aliases_tag, "alias"); alias_tag; alias_tag = alias_tag->next) {
</span><span class="cx">                                                 char *aname = (char *) switch_xml_attr_soft(alias_tag, "name");
</span><del>-                                                if (!switch_strlen_zero(aname)) {
</del><ins>+                                                if (!zstr(aname)) {
</ins><span class="cx">
</span><span class="cx">                                                         if (sofia_glue_add_profile(switch_core_strdup(profile->pool, aname), profile) == SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                                                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Adding Alias [%s] for profile [%s]\n", aname, profile->name);
</span><span class="lines">@@ -3083,7 +3083,7 @@
</span><span class="cx"> {
</span><span class="cx">         sofia_gateway_t *gateway = NULL;
</span><span class="cx">
</span><del>-        if (sofia_private && !switch_strlen_zero(sofia_private->gateway_name)) {
</del><ins>+        if (sofia_private && !zstr(sofia_private->gateway_name)) {
</ins><span class="cx">                 gateway = sofia_reg_find_gateway(sofia_private->gateway_name);
</span><span class="cx">                 sofia_private->destroy_me = 1;
</span><span class="cx">         }
</span><span class="lines">@@ -3526,7 +3526,7 @@
</span><span class="cx">                         sdp_parser_t *parser;
</span><span class="cx">                         sdp_session_t *sdp;
</span><span class="cx">                         
</span><del>-                        if (!switch_strlen_zero(tech_pvt->remote_sdp_str) && !strcmp(tech_pvt->remote_sdp_str, r_sdp)) {
</del><ins>+                        if (!zstr(tech_pvt->remote_sdp_str) && !strcmp(tech_pvt->remote_sdp_str, r_sdp)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Duplicate SDP\n%s\n", r_sdp);
</span><span class="cx">                                 is_dup_sdp = 1;
</span><span class="cx">                         } else {
</span><span class="lines">@@ -4369,7 +4369,7 @@
</span><span class="cx">                                                                         sofia_set_flag_locked(b_tech_pvt, TFLAG_BYE);
</span><span class="cx">                                                                         nua_bye(b_tech_pvt->nh,
</span><span class="cx">                                                                                         SIPTAG_REASON_STR("Q.850;cause=16;text=\"normal_clearing\""),
</span><del>-                                                                                        TAG_IF(!switch_strlen_zero(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</del><ins>+                                                                                        TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</ins><span class="cx">                                                                                         TAG_END());
</span><span class="cx">                                                                 }
</span><span class="cx">                                                         } else {
</span><span class="lines">@@ -4429,11 +4429,11 @@
</span><span class="cx">                                                                         const char *idest = switch_channel_get_variable(hup_channel, "inline_destination");
</span><span class="cx">                                                                         ext = switch_channel_get_variable(hup_channel, "destination_number");
</span><span class="cx">
</span><del>-                                                                        if (!switch_strlen_zero(full_ref_by)) {
</del><ins>+                                                                        if (!zstr(full_ref_by)) {
</ins><span class="cx">                                                                                 switch_channel_set_variable(t_channel, SOFIA_SIP_HEADER_PREFIX "Referred-By", full_ref_by);
</span><span class="cx">                                                                         }
</span><span class="cx">
</span><del>-                                                                        if (!switch_strlen_zero(full_ref_to)) {
</del><ins>+                                                                        if (!zstr(full_ref_to)) {
</ins><span class="cx">                                                                                 switch_channel_set_variable(t_channel, SOFIA_REFER_TO_VARIABLE, full_ref_to);
</span><span class="cx">                                                                         }
</span><span class="cx">                                                                         
</span><span class="lines">@@ -4477,7 +4477,7 @@
</span><span class="cx">                                                                 port = refer_to->r_url->url_port;
</span><span class="cx">                                                         }
</span><span class="cx">
</span><del>-                                                        if (switch_strlen_zero(port)) {
</del><ins>+                                                        if (zstr(port)) {
</ins><span class="cx">                                                                 port = "5060";
</span><span class="cx">                                                         }
</span><span class="cx">                                                         
</span><span class="lines">@@ -4517,11 +4517,11 @@
</span><span class="cx">
</span><span class="cx">                                                         switch_channel_set_variable(channel, SOFIA_REPLACES_HEADER, rep);
</span><span class="cx">
</span><del>-                                                        if (!switch_strlen_zero(full_ref_by)) {
</del><ins>+                                                        if (!zstr(full_ref_by)) {
</ins><span class="cx">                                                                 switch_channel_set_variable(channel, SOFIA_SIP_HEADER_PREFIX "Referred-By", full_ref_by);
</span><span class="cx">                                                         }
</span><span class="cx">
</span><del>-                                                        if (!switch_strlen_zero(full_ref_to)) {
</del><ins>+                                                        if (!zstr(full_ref_to)) {
</ins><span class="cx">                                                                 switch_channel_set_variable(channel, SOFIA_REFER_TO_VARIABLE, full_ref_to);
</span><span class="cx">                                                         }
</span><span class="cx">
</span><span class="lines">@@ -4564,10 +4564,10 @@
</span><span class="cx">                         if ((b_session = switch_core_session_locate(br))) {
</span><span class="cx">                                 switch_channel_t *b_channel = switch_core_session_get_channel(b_session);
</span><span class="cx">                                 switch_channel_set_variable(channel, "transfer_fallback_extension", from->a_user);
</span><del>-                                if (!switch_strlen_zero(full_ref_by)) {
</del><ins>+                                if (!zstr(full_ref_by)) {
</ins><span class="cx">                                         switch_channel_set_variable(b_channel, SOFIA_SIP_HEADER_PREFIX "Referred-By", full_ref_by);
</span><span class="cx">                                 }
</span><del>-                                if (!switch_strlen_zero(full_ref_to)) {
</del><ins>+                                if (!zstr(full_ref_to)) {
</ins><span class="cx">                                         switch_channel_set_variable(b_channel, SOFIA_REFER_TO_VARIABLE, full_ref_to);
</span><span class="cx">                                 }
</span><span class="cx">
</span><span class="lines">@@ -4688,7 +4688,7 @@
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="cx">                 if ((clientcode_header = sofia_glue_get_unknown_header(sip, "x-clientcode"))) {
</span><del>-                        if (!switch_strlen_zero(clientcode_header)) {
</del><ins>+                        if (!zstr(clientcode_header)) {
</ins><span class="cx">                                 switch_channel_set_variable(channel, "call_clientcode", clientcode_header);
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_NOTICE, "Setting CMC to %s\n", clientcode_header);
</span><span class="cx">                                 nua_respond(nh, SIP_200_OK, NUTAG_WITH_THIS(nua), TAG_END());
</span><span class="lines">@@ -4697,7 +4697,7 @@
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="cx">                 if ((rec_header = sofia_glue_get_unknown_header(sip, "record"))) {
</span><del>-                        if (switch_strlen_zero(profile->record_template)) {
</del><ins>+                        if (zstr(profile->record_template)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "Record attempted but no template defined.\n");
</span><span class="cx">                                 nua_respond(nh, 488, "Recording not enabled", NUTAG_WITH_THIS(nua), TAG_END());
</span><span class="cx">                         } else {
</span><span class="lines">@@ -4810,16 +4810,16 @@
</span><span class="cx">                 user = url->url_user;
</span><span class="cx">                 host = url->url_host;
</span><span class="cx">                 port = url->url_port;
</span><del>-                if (!switch_strlen_zero(url->url_params)) {
</del><ins>+                if (!zstr(url->url_params)) {
</ins><span class="cx">                         switch_channel_set_variable(channel, params_var, url->url_params);
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(user)) {
</del><ins>+        if (zstr(user)) {
</ins><span class="cx">                 user = "nobody";
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(host)) {
</del><ins>+        if (zstr(host)) {
</ins><span class="cx">                 host = "nowhere";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -4926,7 +4926,7 @@
</span><span class="cx">                         contact_host = sip->sip_contact->m_url->url_host;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(contact_host)) {
</del><ins>+                if (!zstr(contact_host)) {
</ins><span class="cx">                         for (x = 0; x < profile->nat_acl_count; x++) {
</span><span class="cx">                                 last_acl = profile->nat_acl[x];
</span><span class="cx">                                 if (!(ok = switch_check_network_list_ip(contact_host, last_acl))) {
</span><span class="lines">@@ -4992,7 +4992,7 @@
</span><span class="cx">                                                                                  "found auth ip [%s] header of [%s]\n",
</span><span class="cx">                                                                                  un->un_name, un->un_value
</span><span class="cx">                                                                                  );
</span><del>-                                                if (!switch_strlen_zero(un->un_value)) {
</del><ins>+                                                if (!zstr(un->un_value)) {
</ins><span class="cx">                                                         for (x = 0; x < profile->acl_count; x++) {
</span><span class="cx">                                                                 last_acl = profile->acl[x];
</span><span class="cx">                                                                 if ((ok = switch_check_network_list_ip_token(un->un_value, last_acl, &token))) {
</span><span class="lines">@@ -5139,7 +5139,7 @@
</span><span class="cx">                 from_host = sip->sip_from->a_url->url_host;
</span><span class="cx">                 channel_name = url_set_chanvars(session, sip->sip_from->a_url, sip_from);
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(from_user)) {
</del><ins>+                if (!zstr(from_user)) {
</ins><span class="cx">                         if (*from_user == '+') {
</span><span class="cx">                                 switch_channel_set_variable(channel, "sip_from_user_stripped", (const char *) (from_user + 1));
</span><span class="cx">                         } else {
</span><span class="lines">@@ -5156,10 +5156,10 @@
</span><span class="cx">                 switch_channel_set_variable(channel, "sofia_profile_name", profile->name);
</span><span class="cx">                 switch_channel_set_variable(channel, "sofia_profile_domain_name", profile->domain_name);
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(sip->sip_from->a_display)) {
</del><ins>+                if (!zstr(sip->sip_from->a_display)) {
</ins><span class="cx">                         displayname = sip->sip_from->a_display;
</span><span class="cx">                 } else {
</span><del>-                        displayname = switch_strlen_zero(from_user) ? "unknown" : from_user;
</del><ins>+                        displayname = zstr(from_user) ? "unknown" : from_user;
</ins><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -5167,12 +5167,12 @@
</span><span class="cx">                 if (rpid->rpid_url && rpid->rpid_url->url_user) {
</span><span class="cx">                         char *full_rpid_header = sip_header_as_string(nh->nh_home, (void *) rpid);
</span><span class="cx">                         from_user = rpid->rpid_url->url_user;
</span><del>-                        if (!switch_strlen_zero(full_rpid_header)) {
</del><ins>+                        if (!zstr(full_rpid_header)) {
</ins><span class="cx">                                 switch_channel_set_variable(channel, "sip_Remote-Party-ID", full_rpid_header);
</span><span class="cx">                         }
</span><span class="cx">
</span><span class="cx">                 }
</span><del>-                if (!switch_strlen_zero(rpid->rpid_display)) {
</del><ins>+                if (!zstr(rpid->rpid_display)) {
</ins><span class="cx">                         displayname = rpid->rpid_display;
</span><span class="cx">                 }
</span><span class="cx">                 switch_channel_set_variable(channel, "sip_cid_type", "rpid");
</span><span class="lines">@@ -5182,11 +5182,11 @@
</span><span class="cx">                 if (passerted->paid_url && passerted->paid_url->url_user) {
</span><span class="cx">                         char *full_paid_header = sip_header_as_string(nh->nh_home, (void *) passerted);
</span><span class="cx">                         from_user = passerted->paid_url->url_user;
</span><del>-                        if (!switch_strlen_zero(full_paid_header)) {
</del><ins>+                        if (!zstr(full_paid_header)) {
</ins><span class="cx">                                 switch_channel_set_variable(channel, "sip_P-Asserted-Identity", from_user);
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><del>-                if (!switch_strlen_zero(passerted->paid_display)) {
</del><ins>+                if (!zstr(passerted->paid_display)) {
</ins><span class="cx">                         displayname = passerted->paid_display;
</span><span class="cx">                 }
</span><span class="cx">                 switch_channel_set_variable(channel, "sip_cid_type", "pid");
</span><span class="lines">@@ -5196,12 +5196,12 @@
</span><span class="cx">                 if (ppreferred->ppid_url && ppreferred->ppid_url->url_user) {
</span><span class="cx">                         char *full_ppid_header = sip_header_as_string(nh->nh_home, (void *) ppreferred);
</span><span class="cx">                         from_user = ppreferred->ppid_url->url_user;
</span><del>-                        if (!switch_strlen_zero(full_ppid_header)) {
</del><ins>+                        if (!zstr(full_ppid_header)) {
</ins><span class="cx">                                 switch_channel_set_variable(channel, "sip_P-Preferred-Identity", full_ppid_header);
</span><span class="cx">                         }
</span><span class="cx">                         
</span><span class="cx">                 }
</span><del>-                if (!switch_strlen_zero(ppreferred->ppid_display)) {
</del><ins>+                if (!zstr(ppreferred->ppid_display)) {
</ins><span class="cx">                         displayname = ppreferred->ppid_display;
</span><span class="cx">                 }
</span><span class="cx">                 switch_channel_set_variable(channel, "sip_cid_type", "pid");
</span><span class="lines">@@ -5346,7 +5346,7 @@
</span><span class="cx">
</span><span class="cx">                 check_decode(referred_by_user, session);
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(referred_by_user)) {
</del><ins>+                if (!zstr(referred_by_user)) {
</ins><span class="cx">                         if (*referred_by_user == '+') {
</span><span class="cx">                                 switch_channel_set_variable(channel, "sip_referred_by_user_stripped", (const char *) (referred_by_user + 1));
</span><span class="cx">                         } else {
</span><span class="lines">@@ -5383,7 +5383,7 @@
</span><span class="cx">                 switch_channel_set_variable(channel, "sip_subject", sip->sip_subject->g_string);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (sip->sip_user_agent && !switch_strlen_zero(sip->sip_user_agent->g_string)) {
</del><ins>+        if (sip->sip_user_agent && !zstr(sip->sip_user_agent->g_string)) {
</ins><span class="cx">                 switch_channel_set_variable(channel, "sip_user_agent", sip->sip_user_agent->g_string);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -5590,7 +5590,7 @@
</span><span class="cx">
</span><span class="cx">                 if ((privacy = sip_privacy(sip))) {
</span><span class="cx">                         char *full_priv_header = sip_header_as_string(nh->nh_home, (void *) privacy);
</span><del>-                        if (!switch_strlen_zero(full_priv_header)) {
</del><ins>+                        if (!zstr(full_priv_header)) {
</ins><span class="cx">                                 switch_channel_set_variable(channel, "sip_Privacy", full_priv_header);
</span><span class="cx">                         }
</span><span class="cx">                         if (msg_params_find(privacy->priv_values, "id")) {
</span><span class="lines">@@ -5603,7 +5603,7 @@
</span><span class="cx">                         if (!strncasecmp(un->un_name, "Diversion", 9)) {
</span><span class="cx">                                 /* Basic Diversion Support for Diversion Indication in SIP */
</span><span class="cx">                                 /* draft-levy-sip-diversion-08 */
</span><del>-                                if (!switch_strlen_zero(un->un_value)) {
</del><ins>+                                if (!zstr(un->un_value)) {
</ins><span class="cx">                                         char *tmp_name;
</span><span class="cx">                                         if ((tmp_name = switch_mprintf("%s%s", SOFIA_SIP_HEADER_PREFIX, un->un_name))) {
</span><span class="cx">                                                 switch_channel_set_variable(channel, tmp_name, un->un_value);
</span><span class="lines">@@ -5615,7 +5615,7 @@
</span><span class="cx">                         } else if (!strcasecmp(un->un_name, "X-FS-Support")) {
</span><span class="cx">                                 tech_pvt->x_freeswitch_support_remote = switch_core_session_strdup(session, un->un_value);
</span><span class="cx">                         } else if (!strncasecmp(un->un_name, "X-", 2) || !strncasecmp(un->un_name, "P-", 2)) {
</span><del>-                                if (!switch_strlen_zero(un->un_value)) {
</del><ins>+                                if (!zstr(un->un_value)) {
</ins><span class="cx">                                         char new_name[512] = "";
</span><span class="cx">                                         int reps = 0;
</span><span class="cx">                                         for(;;) {
</span><span class="lines">@@ -5768,24 +5768,24 @@
</span><span class="cx">                         switch_caller_profile_t *acp = a_tech_pvt->caller_profile;
</span><span class="cx">                         
</span><span class="cx">                         if (ua && switch_stristr("snom", ua)) {
</span><del>-                                if (switch_strlen_zero(acp->caller_id_name)) {
</del><ins>+                                if (zstr(acp->caller_id_name)) {
</ins><span class="cx">                                         snprintf(message, sizeof(message), "From:\r\nTo: %s\r\n", acp->caller_id_number);
</span><span class="cx">                                 } else {
</span><span class="cx">                                         snprintf(message, sizeof(message), "From:\r\nTo: \"%s\" %s\r\n", acp->caller_id_name, acp->caller_id_number);
</span><span class="cx">                                 }
</span><span class="cx">                                 nua_info(b_tech_pvt->nh,
</span><span class="cx">                                                  SIPTAG_CONTENT_TYPE_STR("message/sipfrag"),
</span><del>-                                                 TAG_IF(!switch_strlen_zero(b_tech_pvt->user_via), SIPTAG_VIA_STR(b_tech_pvt->user_via)),
</del><ins>+                                                 TAG_IF(!zstr(b_tech_pvt->user_via), SIPTAG_VIA_STR(b_tech_pvt->user_via)),
</ins><span class="cx">                                                  SIPTAG_PAYLOAD_STR(message), TAG_END());
</span><span class="cx">                         } else if (ua && switch_stristr("polycom", ua)) {
</span><del>-                                if (switch_strlen_zero(acp->caller_id_name)) {
</del><ins>+                                if (zstr(acp->caller_id_name)) {
</ins><span class="cx">                                         snprintf(message, sizeof(message), "P-Asserted-Identity: \"%s\" <%s>", acp->caller_id_number, acp->caller_id_number);
</span><span class="cx">                                 } else {
</span><span class="cx">                                         snprintf(message, sizeof(message), "P-Asserted-Identity: \"%s\" <%s>", acp->caller_id_name, acp->caller_id_number);
</span><span class="cx">                                 }
</span><span class="cx">                                 nua_update(b_tech_pvt->nh,
</span><del>-                                                 TAG_IF(!switch_strlen_zero_buf(message), SIPTAG_HEADER_STR(message)),
-                                                 TAG_IF(!switch_strlen_zero(b_tech_pvt->user_via), SIPTAG_VIA_STR(b_tech_pvt->user_via)),
</del><ins>+                                                 TAG_IF(!zstr_buf(message), SIPTAG_HEADER_STR(message)),
+                                                 TAG_IF(!zstr(b_tech_pvt->user_via), SIPTAG_VIA_STR(b_tech_pvt->user_via)),
</ins><span class="cx">                                                  TAG_END());
</span><span class="cx">                         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_sofiasofia_gluec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_glue.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_glue.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_glue.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -178,7 +178,7 @@
</span><span class="cx">                                         tech_pvt->owner_id, tech_pvt->session_id, family, ip, username, family, ip,
</span><span class="cx">                                         srbuf,
</span><span class="cx">                                         port,
</span><del>-                                        (!switch_strlen_zero(tech_pvt->local_crypto_key)
</del><ins>+                                        (!zstr(tech_pvt->local_crypto_key)
</ins><span class="cx">                                         && sofia_test_flag(tech_pvt,TFLAG_SECURE)) ? "S" : "");
</span><span class="cx">
</span><span class="cx">         if (tech_pvt->rm_encoding) {
</span><span class="lines">@@ -276,7 +276,7 @@
</span><span class="cx">                 switch_snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf), "a=%s\n", sr);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(tech_pvt->local_crypto_key) && sofia_test_flag(tech_pvt, TFLAG_SECURE)) {
</del><ins>+        if (!zstr(tech_pvt->local_crypto_key) && sofia_test_flag(tech_pvt, TFLAG_SECURE)) {
</ins><span class="cx">                 switch_snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf), "a=crypto:%s\n", tech_pvt->local_crypto_key);
</span><span class="cx">                 //switch_snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf), "a=encryption:optional\n");
</span><span class="cx"> #if 0
</span><span class="lines">@@ -571,7 +571,7 @@
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(stun_ip)) {
</del><ins>+                if (zstr(stun_ip)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "STUN Failed! NO STUN SERVER\n");
</span><span class="cx">                         goto out;
</span><span class="cx">                 }
</span><span class="lines">@@ -632,7 +632,7 @@
</span><span class="cx">         sip_unknown_t *un;
</span><span class="cx">         for (un = sip->sip_unknown; un; un = un->un_next) {
</span><span class="cx">                 if (!strcasecmp(un->un_name, name)) {
</span><del>-                        if (!switch_strlen_zero(un->un_value)) {
</del><ins>+                        if (!zstr(un->un_value)) {
</ins><span class="cx">                                 return un->un_value;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="lines">@@ -670,7 +670,7 @@
</span><span class="cx">         sdp_port = tech_pvt->local_sdp_audio_port;
</span><span class="cx">
</span><span class="cx">         if (!(use_ip = switch_channel_get_variable(tech_pvt->channel, "rtp_adv_audio_ip"))
</span><del>-                && !switch_strlen_zero(tech_pvt->profile->extrtpip)) {
</del><ins>+                && !zstr(tech_pvt->profile->extrtpip)) {
</ins><span class="cx">                         use_ip = tech_pvt->profile->extrtpip;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -738,7 +738,7 @@
</span><span class="cx">         sdp_port = tech_pvt->local_sdp_video_port;
</span><span class="cx">
</span><span class="cx">         if (!(use_ip = switch_channel_get_variable(tech_pvt->channel, "rtp_adv_video_ip"))
</span><del>-                && !switch_strlen_zero(tech_pvt->profile->extrtpip)) {
</del><ins>+                && !zstr(tech_pvt->profile->extrtpip)) {
</ins><span class="cx">                         use_ip = tech_pvt->profile->extrtpip;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1005,7 +1005,7 @@
</span><span class="cx">         int x;
</span><span class="cx">         const char *val;
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(tech_pvt->remote_sdp_str)) {
</del><ins>+        if (zstr(tech_pvt->remote_sdp_str)) {
</ins><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1137,7 +1137,7 @@
</span><span class="cx">         char *new_sdp;
</span><span class="cx">         int bad = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(tech_pvt->local_sdp_str)) {
</del><ins>+        if (zstr(tech_pvt->local_sdp_str)) {
</ins><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1148,7 +1148,7 @@
</span><span class="cx">          return;
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(tech_pvt->adv_sdp_audio_ip) || !tech_pvt->adv_sdp_audio_port) {
</del><ins>+        if (zstr(tech_pvt->adv_sdp_audio_ip) || !tech_pvt->adv_sdp_audio_port) {
</ins><span class="cx">          if (sofia_glue_tech_choose_port(tech_pvt, 1) != SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(tech_pvt->session), SWITCH_LOG_ERROR, "%s I/O Error\n", switch_channel_get_name(tech_pvt->channel));
</span><span class="cx">                         return;
</span><span class="lines">@@ -1360,7 +1360,7 @@
</span><span class="cx"> switch_channel_variable_last(channel);
</span><span class="cx"> }
</span><span class="cx">
</span><del>- if (!switch_strlen_zero((char*)stream.data)) {
</del><ins>+ if (!zstr((char*)stream.data)) {
</ins><span class="cx"> extra_headers = stream.data;
</span><span class="cx"> } else {
</span><span class="cx">                 switch_safe_free(stream.data);
</span><span class="lines">@@ -1380,7 +1380,7 @@
</span><span class="cx">
</span><span class="cx">         for (un = sip->sip_unknown; un; un = un->un_next) {
</span><span class="cx">                 if (!strncasecmp(un->un_name, "X-", 2) || !strncasecmp(un->un_name, "P-", 2)) {
</span><del>-                        if (!switch_strlen_zero(un->un_value)) {
</del><ins>+                        if (!zstr(un->un_value)) {
</ins><span class="cx">                                 switch_snprintf(name, sizeof(name), "%s%s", prefix, un->un_name);
</span><span class="cx">                                 switch_channel_set_variable(channel, name, un->un_value);
</span><span class="cx">                         }
</span><span class="lines">@@ -1448,7 +1448,7 @@
</span><span class="cx">                                                                                 format,
</span><span class="cx">                                                                                 cid_name,
</span><span class="cx">                                                                                 cid_num,
</span><del>-                                                                                !switch_strlen_zero(cid_num) ? "@" : "",
</del><ins>+                                                                                !zstr(cid_num) ? "@" : "",
</ins><span class="cx">                                                                                 sipip);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1482,7 +1482,7 @@
</span><span class="cx">                 const char *from_var = switch_channel_get_variable(tech_pvt->channel, "sip_from_uri");
</span><span class="cx">                 const char *from_display = switch_channel_get_variable(tech_pvt->channel, "sip_from_display");
</span><span class="cx">                 
</span><del>-                if (switch_strlen_zero(tech_pvt->dest)) {
</del><ins>+                if (zstr(tech_pvt->dest)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(tech_pvt->session), SWITCH_LOG_ERROR, "URL Error!\n");
</span><span class="cx">                         return SWITCH_STATUS_FALSE;
</span><span class="cx">                 }
</span><span class="lines">@@ -1501,15 +1501,15 @@
</span><span class="cx">                         } else {
</span><span class="cx">                                 use_from_str = switch_core_session_sprintf(tech_pvt->session, "sip:%s", from_var);
</span><span class="cx">                         }
</span><del>-                } else if (!switch_strlen_zero(tech_pvt->gateway_from_str)) {
</del><ins>+                } else if (!zstr(tech_pvt->gateway_from_str)) {
</ins><span class="cx">                         use_from_str = tech_pvt->gateway_from_str;
</span><span class="cx">                 } else {
</span><span class="cx">                         use_from_str = tech_pvt->from_str;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(tech_pvt->gateway_from_str)) {
</del><ins>+                if (!zstr(tech_pvt->gateway_from_str)) {
</ins><span class="cx">                         rpid_domain = switch_core_session_strdup(session, tech_pvt->gateway_from_str);
</span><del>-                } else if (!switch_strlen_zero(tech_pvt->from_str)) {
</del><ins>+                } else if (!zstr(tech_pvt->from_str)) {
</ins><span class="cx">                         rpid_domain = switch_core_session_strdup(session, tech_pvt->from_str);
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -1529,7 +1529,7 @@
</span><span class="cx">                  * Ignore transport chanvar and uri parameter for gateway connections
</span><span class="cx">                  * since all of them have been already taken care of in mod_sofia.c:sofia_outgoing_channel()
</span><span class="cx">                  */
</span><del>-                if (tech_pvt->transport == SOFIA_TRANSPORT_UNKNOWN && switch_strlen_zero(tech_pvt->gateway_name)) {
</del><ins>+                if (tech_pvt->transport == SOFIA_TRANSPORT_UNKNOWN && zstr(tech_pvt->gateway_name)) {
</ins><span class="cx">                         if ((p = (char *) switch_stristr("port=", url))) {
</span><span class="cx">                                 p += 5;
</span><span class="cx">                                 tech_pvt->transport = sofia_glue_str2transport(p);
</span><span class="lines">@@ -1553,7 +1553,7 @@
</span><span class="cx">                         return SWITCH_STATUS_FALSE;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(tech_pvt->invite_contact)) {
</del><ins>+                if (zstr(tech_pvt->invite_contact)) {
</ins><span class="cx">                         const char * contact;
</span><span class="cx">                         if ((contact = switch_channel_get_variable(channel, "sip_contact_user"))) {
</span><span class="cx">                                 char *ip_addr;
</span><span class="lines">@@ -1740,7 +1740,7 @@
</span><span class="cx">                 sofia_glue_tech_patch_sdp(tech_pvt);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(tech_pvt->dest)) {
</del><ins>+        if (!zstr(tech_pvt->dest)) {
</ins><span class="cx">                 dst = sofia_glue_get_destination(tech_pvt->dest);
</span><span class="cx">
</span><span class="cx">                 if (dst->route_uri) {
</span><span class="lines">@@ -1766,17 +1766,17 @@
</span><span class="cx">                          NUTAG_AUTOANSWER(0),
</span><span class="cx">                          NUTAG_SESSION_TIMER(session_timeout),
</span><span class="cx">                          TAG_IF(tech_pvt->redirected, NUTAG_URL(tech_pvt->redirected)),
</span><del>-                         TAG_IF(!switch_strlen_zero(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
-                         TAG_IF(!switch_strlen_zero(tech_pvt->rpid), SIPTAG_REMOTE_PARTY_ID_STR(tech_pvt->rpid)),
-                         TAG_IF(!switch_strlen_zero(tech_pvt->preferred_id), SIPTAG_P_PREFERRED_IDENTITY_STR(tech_pvt->preferred_id)),
-                         TAG_IF(!switch_strlen_zero(tech_pvt->asserted_id), SIPTAG_P_ASSERTED_IDENTITY_STR(tech_pvt->asserted_id)),
-                         TAG_IF(!switch_strlen_zero(tech_pvt->privacy), SIPTAG_PRIVACY_STR(tech_pvt->privacy)),
-                         TAG_IF(!switch_strlen_zero(alert_info), SIPTAG_HEADER_STR(alert_info)),
-                         TAG_IF(!switch_strlen_zero(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
</del><ins>+                         TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
+                         TAG_IF(!zstr(tech_pvt->rpid), SIPTAG_REMOTE_PARTY_ID_STR(tech_pvt->rpid)),
+                         TAG_IF(!zstr(tech_pvt->preferred_id), SIPTAG_P_PREFERRED_IDENTITY_STR(tech_pvt->preferred_id)),
+                         TAG_IF(!zstr(tech_pvt->asserted_id), SIPTAG_P_ASSERTED_IDENTITY_STR(tech_pvt->asserted_id)),
+                         TAG_IF(!zstr(tech_pvt->privacy), SIPTAG_PRIVACY_STR(tech_pvt->privacy)),
+                         TAG_IF(!zstr(alert_info), SIPTAG_HEADER_STR(alert_info)),
+                         TAG_IF(!zstr(extra_headers), SIPTAG_HEADER_STR(extra_headers)),
</ins><span class="cx">                          SIPTAG_HEADER_STR("X-FS-Support: "FREESWITCH_SUPPORT),
</span><del>-                         TAG_IF(!switch_strlen_zero(max_forwards), SIPTAG_MAX_FORWARDS_STR(max_forwards)),
-                         TAG_IF(!switch_strlen_zero(route_uri), NUTAG_PROXY(route_uri)),
-                         TAG_IF(!switch_strlen_zero(route), SIPTAG_ROUTE_STR(route)),
</del><ins>+                         TAG_IF(!zstr(max_forwards), SIPTAG_MAX_FORWARDS_STR(max_forwards)),
+                         TAG_IF(!zstr(route_uri), NUTAG_PROXY(route_uri)),
+                         TAG_IF(!zstr(route), SIPTAG_ROUTE_STR(route)),
</ins><span class="cx">                          SOATAG_ADDRESS(tech_pvt->adv_sdp_audio_ip),
</span><span class="cx">                          SOATAG_USER_SDP_STR(tech_pvt->local_sdp_str),
</span><span class="cx">                          SOATAG_REUSE_REJECTED(1),
</span><span class="lines">@@ -1828,7 +1828,7 @@
</span><span class="cx">
</span><span class="cx">                 nua_invite(tech_pvt->nh2,
</span><span class="cx">                                  SIPTAG_CONTACT_STR(contact_url),
</span><del>-                                 TAG_IF(!switch_strlen_zero(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</del><ins>+                                 TAG_IF(!zstr(tech_pvt->user_via), SIPTAG_VIA_STR(tech_pvt->user_via)),
</ins><span class="cx">                                  SOATAG_ADDRESS(tech_pvt->adv_sdp_audio_ip),
</span><span class="cx">                                  SOATAG_USER_SDP_STR(tech_pvt->local_sdp_str),
</span><span class="cx">                                  SOATAG_REUSE_REJECTED(1),
</span><span class="lines">@@ -2606,7 +2606,7 @@
</span><span class="cx">         char *codec_order[SWITCH_MAX_CODECS];
</span><span class="cx">         const switch_codec_implementation_t *codecs[SWITCH_MAX_CODECS] = { 0 };
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(codec_string)) {
</del><ins>+        if (!zstr(codec_string)) {
</ins><span class="cx">                 char *tmp_codec_string;
</span><span class="cx">                 if ((tmp_codec_string = strdup(codec_string))) {
</span><span class="cx">                         num_codecs = switch_separate_string(tmp_codec_string, ',', codec_order, SWITCH_MAX_CODECS);
</span><span class="lines">@@ -2622,7 +2622,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         for (attr = sdp->sdp_attributes; attr; attr = attr->a_next) {
</span><del>-                if (switch_strlen_zero(attr->a_name)) {
</del><ins>+                if (zstr(attr->a_name)) {
</ins><span class="cx">                         continue;
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -2638,7 +2638,7 @@
</span><span class="cx">                         switch_snprintf(buf + strlen(buf), sizeof(buf) - strlen(buf), ",t38");
</span><span class="cx">                 } else if (m->m_type == sdp_media_audio && m->m_port) {
</span><span class="cx">                         for (attr = m->m_attributes; attr; attr = attr->a_next) {
</span><del>-                                if (switch_strlen_zero(attr->a_name)) {
</del><ins>+                                if (zstr(attr->a_name)) {
</ins><span class="cx">                                         continue;
</span><span class="cx">                                 }
</span><span class="cx">                                 if (!strcasecmp(attr->a_name, "ptime") && attr->a_value) {
</span><span class="lines">@@ -2744,7 +2744,7 @@
</span><span class="cx">         switch_assert(tech_pvt != NULL);
</span><span class="cx">         switch_assert(r_sdp != NULL);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(r_sdp)) {
</del><ins>+        if (zstr(r_sdp)) {
</ins><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2903,7 +2903,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         for (attr = sdp->sdp_attributes; attr; attr = attr->a_next) {
</span><del>-                if (switch_strlen_zero(attr->a_name)) {
</del><ins>+                if (zstr(attr->a_name)) {
</ins><span class="cx">                         continue;
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -2975,7 +2975,7 @@
</span><span class="cx">                                         ptime = atoi(attr->a_value);
</span><span class="cx">                                 } else if (!strcasecmp(attr->a_name, "maxptime") && attr->a_value) {
</span><span class="cx">                                         maxptime = atoi(attr->a_value);
</span><del>-                                } else if (!got_crypto && !strcasecmp(attr->a_name, "crypto") && !switch_strlen_zero(attr->a_value)) {
</del><ins>+                                } else if (!got_crypto && !strcasecmp(attr->a_name, "crypto") && !zstr(attr->a_value)) {
</ins><span class="cx">                                         int crypto_tag;
</span><span class="cx">
</span><span class="cx">                                         if (m->m_proto != sdp_proto_srtp) {
</span><span class="lines">@@ -3030,7 +3030,7 @@
</span><span class="cx">                                                 tech_pvt->crypto_tag = crypto_tag;
</span><span class="cx">                                                 got_crypto++;
</span><span class="cx">
</span><del>-                                                if (switch_strlen_zero(tech_pvt->local_crypto_key)) {
</del><ins>+                                                if (zstr(tech_pvt->local_crypto_key)) {
</ins><span class="cx">                                                         if (switch_stristr(SWITCH_RTP_CRYPTO_KEY_32, crypto)) {
</span><span class="cx">                                                                 switch_channel_set_variable(tech_pvt->channel, SOFIA_HAS_CRYPTO_VARIABLE, SWITCH_RTP_CRYPTO_KEY_32);
</span><span class="cx">                                                                 sofia_glue_build_crypto(tech_pvt, atoi(crypto), AES_CM_128_HMAC_SHA1_32, SWITCH_RTP_CRYPTO_SEND);
</span><span class="lines">@@ -3075,7 +3075,7 @@
</span><span class="cx">                                 }
</span><span class="cx">                                 
</span><span class="cx">                                 for (map = m->m_rtpmaps; map; map = map->rm_next) {
</span><del>-                                        if (switch_strlen_zero(map->rm_encoding) && map->rm_pt < 96) {
</del><ins>+                                        if (zstr(map->rm_encoding) && map->rm_pt < 96) {
</ins><span class="cx">                                                 match = (map->rm_pt == tech_pvt->pt) ? 1 : 0;
</span><span class="cx">                                         } else {
</span><span class="cx">                                                 match = strcasecmp(switch_str_nil(map->rm_encoding), tech_pvt->iananame) ? 0 : 1;
</span><span class="lines">@@ -3160,7 +3160,7 @@
</span><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Audio Codec Compare [%s:%d:%u:%d]/[%s:%d:%u:%d]\n",
</span><span class="cx">                                                                          rm_encoding, map->rm_pt, (int) map->rm_rate, ptime,
</span><span class="cx">                                                                          imp->iananame, imp->ianacode, codec_rate, imp->microseconds_per_packet / 1000);
</span><del>-                                        if (switch_strlen_zero(map->rm_encoding) && map->rm_pt < 96) {
</del><ins>+                                        if (zstr(map->rm_encoding) && map->rm_pt < 96) {
</ins><span class="cx">                                                 match = (map->rm_pt == imp->ianacode) ? 1 : 0;
</span><span class="cx">                                         } else {
</span><span class="cx">                                                 match = strcasecmp(rm_encoding, imp->iananame) ? 0 : 1;
</span><span class="lines">@@ -3226,7 +3226,7 @@
</span><span class="cx">                                         tech_pvt->iananame = switch_core_session_strdup(session, (char *) mimp->iananame);
</span><span class="cx">                                         tech_pvt->pt = (switch_payload_t) map->rm_pt;
</span><span class="cx">                                         tech_pvt->rm_rate = map->rm_rate;
</span><del>-                                        if (!strcasecmp((char *) mimp->iananame, "ilbc") && switch_strlen_zero((char*)map->rm_fmtp)) {
</del><ins>+                                        if (!strcasecmp((char *) mimp->iananame, "ilbc") && zstr((char*)map->rm_fmtp)) {
</ins><span class="cx">                                                 /* default to 30 when no mode is defined for ilbc ONLY */
</span><span class="cx">                                                 tech_pvt->codec_ms = 30;
</span><span class="cx">                                         } else {
</span><span class="lines">@@ -3994,7 +3994,7 @@
</span><span class="cx">                 if (switch_odbc_handle_exec(profile->master_odbc, sql, &stmt) != SWITCH_ODBC_SUCCESS) {
</span><span class="cx">                         char *err_str;
</span><span class="cx">                         err_str = switch_odbc_handle_get_error(profile->master_odbc, stmt);
</span><del>-                        if (!switch_strlen_zero(err_str)) {
</del><ins>+                        if (!zstr(err_str)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "ERR: [%s]\n[%s]\n", sql, err_str);
</span><span class="cx">                         }
</span><span class="cx">                         switch_safe_free(err_str);
</span><span class="lines">@@ -4225,7 +4225,7 @@
</span><span class="cx">         char *eoc = NULL;
</span><span class="cx">         char *p = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 return NULL;
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_sofiasofia_presencec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -68,7 +68,7 @@
</span><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(type)) {
</del><ins>+        if (!zstr(type)) {
</ins><span class="cx">                 ct = type;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -96,9 +96,9 @@
</span><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(host)) {
</del><ins>+        if (zstr(host)) {
</ins><span class="cx">                 host = profile->domain_name;
</span><del>-                if (switch_strlen_zero(host)) {
</del><ins>+                if (zstr(host)) {
</ins><span class="cx">                         host = prof;
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="lines">@@ -123,9 +123,9 @@
</span><span class="cx">                         *p++ = '\0';
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(p)) {
</del><ins>+                if (zstr(p)) {
</ins><span class="cx">                         p = profile->domain_name;
</span><del>-                        if (switch_strlen_zero(p)) {
</del><ins>+                        if (zstr(p)) {
</ins><span class="cx">                                 p = host;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="lines">@@ -463,11 +463,11 @@
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(event_type)) {
</del><ins>+        if (zstr(event_type)) {
</ins><span class="cx">                 event_type = "presence";
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(alt_event_type)) {
</del><ins>+        if (zstr(alt_event_type)) {
</ins><span class="cx">                 alt_event_type = "presence";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -625,7 +625,7 @@
</span><span class="cx">                         
</span><span class="cx">                         switch_safe_free(sql);
</span><span class="cx">
</span><del>-                        if (!switch_strlen_zero((char *) helper.stream.data)) {
</del><ins>+                        if (!zstr((char *) helper.stream.data)) {
</ins><span class="cx">                                 char *this_sql = (char *) helper.stream.data;
</span><span class="cx">                                 char *next = NULL;
</span><span class="cx">                                 char *last = NULL;
</span><span class="lines">@@ -638,7 +638,7 @@
</span><span class="cx">                                                 }
</span><span class="cx">                                         }
</span><span class="cx">
</span><del>-                                        if (!switch_strlen_zero(this_sql) && (!last || strcmp(last, this_sql))) {
</del><ins>+                                        if (!zstr(this_sql) && (!last || strcmp(last, this_sql))) {
</ins><span class="cx">                                                 sofia_glue_execute_sql(profile, &this_sql, SWITCH_FALSE);
</span><span class="cx">                                                 last = this_sql;
</span><span class="cx">                                         }
</span><span class="lines">@@ -839,13 +839,13 @@
</span><span class="cx">                         switch_url_decode(to_buf);
</span><span class="cx">                         to_user = to_buf;
</span><span class="cx">                 }
</span><del>-                if (argc > 10 && !switch_strlen_zero(argv[9]) && !switch_strlen_zero(argv[10])) {
</del><ins>+                if (argc > 10 && !zstr(argv[9]) && !zstr(argv[10])) {
</ins><span class="cx">                         status = argv[9];
</span><span class="cx">                         rpid = argv[10];
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(proto)) {
</del><ins>+        if (zstr(proto)) {
</ins><span class="cx">                 proto = NULL;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -863,11 +863,11 @@
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "alt_event_type", "dialog");
</span><span class="cx">                 switch_event_add_header(event, SWITCH_STACK_BOTTOM, "event_count", "%d", 0);
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(to_user)) {
</del><ins>+                if (!zstr(to_user)) {
</ins><span class="cx">                         switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "to-user", to_user);
</span><span class="cx">                 }
</span><span class="cx">                 
</span><del>-                if (switch_strlen_zero(state)) {
</del><ins>+                if (zstr(state)) {
</ins><span class="cx">                         switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "unique-id", SOFIA_CHAT_PROTO);
</span><span class="cx">                         switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "channel-state", "CS_HANGUP");
</span><span class="cx">                         switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "answer-state", "resubscribe");
</span><span class="lines">@@ -1004,7 +1004,7 @@
</span><span class="cx">         int kill_handle = 0;
</span><span class="cx">         char expires_str[10] = "";
</span><span class="cx">
</span><del>-        if (argc > 18 && !switch_strlen_zero(argv[17]) && !switch_strlen_zero(argv[18])) {
</del><ins>+        if (argc > 18 && !zstr(argv[17]) && !zstr(argv[18])) {
</ins><span class="cx">                 status = argv[17];
</span><span class="cx">                 rpid = argv[18];
</span><span class="cx">         }
</span><span class="lines">@@ -1012,11 +1012,11 @@
</span><span class="cx">         in = helper->event && helper->event->event_id == SWITCH_EVENT_PRESENCE_IN;
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(rpid)) {
</del><ins>+        if (zstr(rpid)) {
</ins><span class="cx">                 rpid = "unknown";
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(status)) {
</del><ins>+        if (zstr(status)) {
</ins><span class="cx">                 if (!strcasecmp(rpid, "busy")) {
</span><span class="cx">                         status = "Busy";
</span><span class="cx">                 } else if (!strcasecmp(rpid, "unavailable")) {
</span><span class="lines">@@ -1135,9 +1135,9 @@
</span><span class="cx">
</span><span class="cx">                         if (!strcasecmp(state, "cs_hangup")) {
</span><span class="cx">                                 astate = "terminated";
</span><del>-                        } else if (switch_strlen_zero(astate)) {
</del><ins>+                        } else if (zstr(astate)) {
</ins><span class="cx">                                 astate = switch_str_nil(switch_event_get_header(helper->event, "answer-state"));
</span><del>-                                if (switch_strlen_zero(astate)) {
</del><ins>+                                if (zstr(astate)) {
</ins><span class="cx">                                         if (is_dialog) {
</span><span class="cx">                                                 astate = dft_state;
</span><span class="cx">                                         } else {
</span><span class="lines">@@ -1171,7 +1171,7 @@
</span><span class="cx">                                 clean_from_user = switch_mprintf("%s", from_id ? from_id : from_user);
</span><span class="cx">
</span><span class="cx">                                 if (is_dialog) {
</span><del>-                                        if (!switch_strlen_zero(clean_to_user) && !switch_strlen_zero(clean_from_user)) {
</del><ins>+                                        if (!zstr(clean_to_user) && !zstr(clean_from_user)) {
</ins><span class="cx">                                                 stream.write_function(&stream, "<local>\n<identity display=\"%s\">sip:%s@%s</identity>\n", clean_to_user, clean_to_user, host);
</span><span class="cx">                                                 stream.write_function(&stream, "<target uri=\"sip:%s@%s\">\n", clean_to_user, host);
</span><span class="cx">                                                 stream.write_function(&stream, "<param pname=\"+sip.rendering\" pvalue=\"%s\"/>\n",
</span><span class="lines">@@ -1183,7 +1183,7 @@
</span><span class="cx">                                                 stream.write_function(&stream, "</remote>\n");
</span><span class="cx">                                         } else if (!strcasecmp(proto, "park")) {
</span><span class="cx">                                                 stream.write_function(&stream, "<local>\n<identity display=\"parking\">sip:parking@%s;fifo=%s</identity>\n",
</span><del>-                                                                                         host, !switch_strlen_zero(clean_to_user) ? clean_to_user : "unknown");
</del><ins>+                                                                                         host, !zstr(clean_to_user) ? clean_to_user : "unknown");
</ins><span class="cx">                                                 stream.write_function(&stream, "<target uri=\"sip:parking@%s\">\n", host);
</span><span class="cx">                                                 stream.write_function(&stream, "<param pname=\"+sip.rendering\" pvalue=\"no\"/>\n</target>\n</local>\n");
</span><span class="cx">                                                 stream.write_function(&stream, "<remote>\n<identity display=\"parking\">sip:%s</identity>\n", uuid);
</span><span class="lines">@@ -1191,7 +1191,7 @@
</span><span class="cx">                                                 stream.write_function(&stream, "</remote>\n");
</span><span class="cx">                                         } else if (!strcasecmp(proto, "conf")) {
</span><span class="cx">                                                 stream.write_function(&stream, "<local>\n<identity display=\"conference\">sip:conference@%s;conference=%s</identity>\n",
</span><del>-                                                                                         host, !switch_strlen_zero(clean_to_user) ? clean_to_user : "unknown");
</del><ins>+                                                                                         host, !zstr(clean_to_user) ? clean_to_user : "unknown");
</ins><span class="cx">                                                 stream.write_function(&stream, "<target uri=\"sip:conference@%s\">\n", host);
</span><span class="cx">                                                 stream.write_function(&stream, "<param pname=\"+sip.rendering\" pvalue=\"yes\"/>\n</target>\n</local>\n");
</span><span class="cx">                                                 stream.write_function(&stream, "<remote>\n<identity display=\"conference\">sip:%s@%s</identity>\n", uuid, host);
</span><span class="lines">@@ -1214,7 +1214,7 @@
</span><span class="cx">                         ct = "application/dialog-info+xml";
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(astate) && !switch_strlen_zero(uuid) && helper && helper->stream.data && strcmp(helper->last_uuid, uuid)) {
</del><ins>+                if (!zstr(astate) && !zstr(uuid) && helper && helper->stream.data && strcmp(helper->last_uuid, uuid)) {
</ins><span class="cx">                         helper->stream.write_function(&helper->stream, "update sip_dialogs set state='%s' where uuid='%s';", astate, uuid);
</span><span class="cx">
</span><span class="cx">                         switch_copy_string(helper->last_uuid, uuid, sizeof(helper->last_uuid));
</span><span class="lines">@@ -1231,15 +1231,15 @@
</span><span class="cx">                                         rpid = "on-the-phone";
</span><span class="cx">                                 } else if (!strcmp(astate, "confirmed")) {
</span><span class="cx">                                         char *dest = switch_event_get_header(helper->event, "Caller-Destination-Number");
</span><del>-                                        if (switch_strlen_zero(from_id) && !switch_strlen_zero(dest)) {
</del><ins>+                                        if (zstr(from_id) && !zstr(dest)) {
</ins><span class="cx">                                                 from_id = dest;
</span><span class="cx">                                         }
</span><span class="cx">
</span><del>-                                        if (switch_strlen_zero(from_id)) {
</del><ins>+                                        if (zstr(from_id)) {
</ins><span class="cx">                                                 from_id = p_to_user;
</span><span class="cx">                                         }
</span><span class="cx">                                         
</span><del>-                                        if (switch_strlen_zero(from_id)) {
</del><ins>+                                        if (zstr(from_id)) {
</ins><span class="cx">                                                 switch_snprintf(status_line, sizeof(status_line), "On The Phone %s", status);
</span><span class="cx">                                         } else {
</span><span class="cx">                                                 switch_snprintf(status_line, sizeof(status_line), "Talk %s", switch_str_nil(from_id));
</span><span class="lines">@@ -1450,10 +1450,10 @@
</span><span class="cx">
</span><span class="cx">                 display = contact->m_display;
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(display)) {
</del><ins>+                if (zstr(display)) {
</ins><span class="cx">                         if (from) {
</span><span class="cx">                                 display = from->a_display;
</span><del>-                                if (switch_strlen_zero(display)) {
</del><ins>+                                if (zstr(display)) {
</ins><span class="cx">                                         display = "\"user\"";
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="lines">@@ -1481,7 +1481,7 @@
</span><span class="cx">                         int ok = 1;
</span><span class="cx">                         char *last_acl = NULL;
</span><span class="cx">
</span><del>-                        if (!switch_strlen_zero(contact_host)) {
</del><ins>+                        if (!zstr(contact_host)) {
</ins><span class="cx">                                 for (x = 0; x < profile->nat_acl_count; x++) {
</span><span class="cx">                                         last_acl = profile->nat_acl[x];
</span><span class="cx">                                         if (!(ok = switch_check_network_list_ip(contact_host, last_acl))) {
</span><span class="lines">@@ -1922,12 +1922,12 @@
</span><span class="cx">                                 }
</span><span class="cx">
</span><span class="cx">                                 if (!strcasecmp(status_txt, "open")) {
</span><del>-                                        if (switch_strlen_zero(note_txt)) {
</del><ins>+                                        if (zstr(note_txt)) {
</ins><span class="cx">                                                 note_txt = "Available";
</span><span class="cx">                                         }
</span><span class="cx">                                         in = 1;
</span><span class="cx">                                 } else if (!strcasecmp(status_txt, "closed")) {
</span><del>-                                        if (switch_strlen_zero(note_txt)) {
</del><ins>+                                        if (zstr(note_txt)) {
</ins><span class="cx">                                                 note_txt = "Unavailable";
</span><span class="cx">                                         }
</span><span class="cx">                                 }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodendpointsmod_sofiasofia_regc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_reg.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_reg.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_reg.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -508,7 +508,7 @@
</span><span class="cx">                 host = "none";
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(user)) {
</del><ins>+        if (zstr(user)) {
</ins><span class="cx">                 sqlextra = switch_mprintf(" or (sip_host='%q')", host);
</span><span class="cx">         } else {
</span><span class="cx">                 sqlextra = switch_mprintf(" or (sip_user='%q' and sip_host='%q')", user, host);
</span><span class="lines">@@ -822,10 +822,10 @@
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(display)) {
</del><ins>+                if (zstr(display)) {
</ins><span class="cx">                         if (to) {
</span><span class="cx">                                 display = to->a_display;
</span><del>-                                if (switch_strlen_zero(display)) {
</del><ins>+                                if (zstr(display)) {
</ins><span class="cx">                                         display = "\"user\"";
</span><span class="cx">                                 }
</span><span class="cx">                         }
</span><span class="lines">@@ -991,7 +991,7 @@
</span><span class="cx">         if (!authorization || stale) {
</span><span class="cx">                 const char *realm = profile->challenge_realm;
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(realm) || !strcasecmp(realm, "auto_to")) {
</del><ins>+                if (zstr(realm) || !strcasecmp(realm, "auto_to")) {
</ins><span class="cx">                         realm = to_host;
</span><span class="cx">                 } else if (!strcasecmp(realm, "auto_from")) {
</span><span class="cx">                         realm = from_host;
</span><span class="lines">@@ -1320,7 +1320,7 @@
</span><span class="cx">                         contact_host = sip->sip_contact->m_url->url_host;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(contact_host)) {
</del><ins>+                if (!zstr(contact_host)) {
</ins><span class="cx">                         for (x = 0; x < profile->nat_acl_count; x++) {
</span><span class="cx">                                 last_acl = profile->nat_acl[x];
</span><span class="cx">                                 if (!(ok = switch_check_network_list_ip(contact_host, last_acl))) {
</span><span class="lines">@@ -1649,14 +1649,14 @@
</span><span class="cx">
</span><span class="cx">         /* Optional check that auth name == SIP username */
</span><span class="cx">         if ((regtype == REG_REGISTER) && sofia_test_pflag(profile, PFLAG_CHECKUSER)) {
</span><del>-                if (switch_strlen_zero(username) || switch_strlen_zero(to_user) || strcasecmp(to_user, username)) {
</del><ins>+                if (zstr(username) || zstr(to_user) || strcasecmp(to_user, username)) {
</ins><span class="cx">                         /* Names don't match, so fail */
</span><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "SIP username %s does not match auth username\n", switch_str_nil(to_user));
</span><span class="cx">                         goto end;
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(np)) {
</del><ins>+        if (zstr(np)) {
</ins><span class="cx">                 first = 1;
</span><span class="cx">                 sql = switch_mprintf("select nonce from sip_authentication where nonce='%q'", nonce);
</span><span class="cx">                 switch_assert(sql != NULL);
</span><span class="lines">@@ -1726,13 +1726,13 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(profile->reg_domain)) {
</del><ins>+        if (!zstr(profile->reg_domain)) {
</ins><span class="cx">                 domain_name = profile->reg_domain;
</span><span class="cx">         } else {
</span><span class="cx">                 domain_name = realm;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_xml_locate_user("id", switch_strlen_zero(username) ? "nobody" : username,
</del><ins>+        if (switch_xml_locate_user("id", zstr(username) ? "nobody" : username,
</ins><span class="cx">                                                          domain_name, ip, &xml, &domain, &user, &group, params) != SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "Can't find user [%s@%s]\n"
</span><span class="cx">                                                  "You must define a domain called '%s' in your directory and add a user with the id=\"%s\" attribute\n"
</span><span class="lines">@@ -1751,7 +1751,7 @@
</span><span class="cx">         }
</span><span class="cx">         
</span><span class="cx">         if (!(number_alias = (char *) switch_xml_attr(user, "number-alias"))) {
</span><del>-                number_alias = switch_strlen_zero(username) ? "nobody" : username;
</del><ins>+                number_alias = zstr(username) ? "nobody" : username;
</ins><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         dparams = switch_xml_child(domain, "params");
</span><span class="lines">@@ -1854,7 +1854,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(passwd) && switch_strlen_zero(a1_hash)) {
</del><ins>+        if (zstr(passwd) && zstr(a1_hash)) {
</ins><span class="cx">                 ret = AUTH_OK;
</span><span class="cx">                 goto skip_auth;
</span><span class="cx">         }
</span><span class="lines">@@ -1973,7 +1973,7 @@
</span><span class="cx">                                                 const char *val = switch_xml_attr_soft(param, "value");
</span><span class="cx">                                                 sofia_gateway_t *gateway_ptr = NULL;
</span><span class="cx">
</span><del>-                                                if (!switch_strlen_zero(var) && !switch_strlen_zero(val) && (xparams_type[j] == 1 || !strncasecmp(var, "sip-",4) || !strcasecmp(var, "register-gateway")) ) {
</del><ins>+                                                if (!zstr(var) && !zstr(val) && (xparams_type[j] == 1 || !strncasecmp(var, "sip-",4) || !strcasecmp(var, "register-gateway")) ) {
</ins><span class="cx">                                                         if (!switch_event_get_header(*v_event, var)) {
</span><span class="cx">                                                                 if (profile->debug) {
</span><span class="cx">                                                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "event_add_header -> '%s' = '%s'\n",var, val);
</span><span class="lines">@@ -1989,7 +1989,7 @@
</span><span class="cx">                                                                         if ((gateways_tag = switch_xml_child(user, "gateways"))) {
</span><span class="cx">                                                                                 for (gateway_tag = switch_xml_child(gateways_tag, "gateway"); gateway_tag; gateway_tag = gateway_tag->next) {
</span><span class="cx">                                                                                         char *name = (char *) switch_xml_attr_soft(gateway_tag, "name");
</span><del>-                                                                                        if (switch_strlen_zero(name)) {
</del><ins>+                                                                                        if (zstr(name)) {
</ins><span class="cx">                                                                                                 name = "anonymous";
</span><span class="cx">                                                                                         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodevent_handlersmod_cdr_csvmod_cdr_csvc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/event_handlers/mod_cdr_csv/mod_cdr_csv.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/event_handlers/mod_cdr_csv/mod_cdr_csv.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/event_handlers/mod_cdr_csv/mod_cdr_csv.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -372,7 +372,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(globals.default_template)) {
</del><ins>+        if (zstr(globals.default_template)) {
</ins><span class="cx">                 globals.default_template = switch_core_strdup(pool, "default");
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodevent_handlersmod_erlang_eventei_helpersc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/ei_helpers.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/ei_helpers.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/ei_helpers.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -347,7 +347,7 @@
</span><span class="cx"> #endif
</span><span class="cx">                 memcpy(thishostname, nodehost->h_name, EI_MAXHOSTNAMELEN);
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero_buf(thishostname)) {
</del><ins>+        if (zstr_buf(thishostname)) {
</ins><span class="cx">                 gethostname(thishostname, EI_MAXHOSTNAMELEN);
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodevent_handlersmod_erlang_eventhandle_msgc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/handle_msg.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/handle_msg.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/handle_msg.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -465,7 +465,7 @@
</span><span class="cx">         }
</span><span class="cx">         else {
</span><span class="cx">                 switch_core_session_t *session;
</span><del>-                if (!switch_strlen_zero_buf(uuid) && (session = switch_core_session_locate(uuid))) {
</del><ins>+                if (!zstr_buf(uuid) && (session = switch_core_session_locate(uuid))) {
</ins><span class="cx">                         switch_event_t *event;        
</span><span class="cx">                         if (switch_event_create(&event, SWITCH_EVENT_SEND_MESSAGE) == SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                                 
</span><span class="lines">@@ -577,7 +577,7 @@
</span><span class="cx">                 ei_x_encode_atom(rbuf, "badarg");
</span><span class="cx">         } else {
</span><span class="cx">                 switch_core_session_t *session;
</span><del>-                if (!switch_strlen_zero_buf(uuid_str)) {
</del><ins>+                if (!zstr_buf(uuid_str)) {
</ins><span class="cx">                         if ((session = switch_core_session_locate(uuid_str))) {
</span><span class="cx">                                 /* create a new session list element and attach it to this listener */
</span><span class="cx">                                 if ((arity==2 && attach_call_to_pid(listener, &msg->from, session)) ||
</span></span></pre></div>
<a id="freeswitchtrunksrcmodevent_handlersmod_erlang_eventmod_erlang_eventc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/mod_erlang_event.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/mod_erlang_event.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/mod_erlang_event.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -451,7 +451,7 @@
</span><span class="cx">
</span><span class="cx">         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "got data %s after %d milliseconds!\n", xmlstr, i*10);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(xmlstr)) {
</del><ins>+        if (zstr(xmlstr)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "No Result\n");
</span><span class="cx">         } else if (!(xml = switch_xml_parse_str_dynamic(xmlstr, SWITCH_FALSE))) {
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Parsing XML Result!\n");
</span><span class="lines">@@ -848,7 +848,7 @@
</span><span class="cx"> static switch_bool_t check_inbound_acl(listener_t* listener)
</span><span class="cx"> {
</span><span class="cx">         /* check acl to see if inbound connection is allowed */
</span><del>-        if (prefs.acl_count && !switch_strlen_zero(listener->remote_ip)) {
</del><ins>+        if (prefs.acl_count && !zstr(listener->remote_ip)) {
</ins><span class="cx">                 uint32_t x = 0;
</span><span class="cx">                 for (x = 0; x < prefs.acl_count; x++) {
</span><span class="cx">                         if (!switch_check_network_list_ip(listener->remote_ip, prefs.acl[x])) {
</span><span class="lines">@@ -904,7 +904,7 @@
</span><span class="cx">         switch_assert(listener != NULL);
</span><span class="cx">
</span><span class="cx">         if (check_inbound_acl(listener)) {
</span><del>-                if (switch_strlen_zero(listener->remote_ip)) {
</del><ins>+                if (zstr(listener->remote_ip)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Connection Open\n");
</span><span class="cx">                 } else {
</span><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Connection Open from %s\n", listener->remote_ip);/*, listener->remote_port);*/
</span><span class="lines">@@ -1027,11 +1027,11 @@
</span><span class="cx">                 switch_xml_free(xml);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(prefs.ip)) {
</del><ins>+        if (zstr(prefs.ip)) {
</ins><span class="cx">                 set_pref_ip("0.0.0.0");
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(prefs.cookie)) {
</del><ins>+        if (zstr(prefs.cookie)) {
</ins><span class="cx">                 set_pref_cookie("ClueCon");
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1319,7 +1319,7 @@
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Parse Error - need registered name and node!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(argv[0])) {
</del><ins>+        if (zstr(argv[0])) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Missing registered name or module:function!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -1339,7 +1339,7 @@
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">         node = argv[1];
</span><del>-        if (switch_strlen_zero(node)) {
</del><ins>+        if (zstr(node)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Missing node name!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -1451,7 +1451,7 @@
</span><span class="cx">                 "erlang sessions <node_name>\n"
</span><span class="cx">                 "--------------------------------------------------------------------------------\n";
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "%s", usage_string);
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodevent_handlersmod_event_socketmod_event_socketc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/event_handlers/mod_event_socket/mod_event_socket.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/event_handlers/mod_event_socket/mod_event_socket.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/event_handlers/mod_event_socket/mod_event_socket.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -356,7 +356,7 @@
</span><span class="cx">
</span><span class="cx">         host = argv[0];
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(host)) {
</del><ins>+        if (zstr(host)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Missing Host!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -617,7 +617,7 @@
</span><span class="cx"> goto end;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(action)) {
</del><ins>+                if (zstr(action)) {
</ins><span class="cx">                         stream->write_function(stream, "<data><reply type=\"error\">Invalid Syntax</reply></data>\n");
</span><span class="cx"> goto end;
</span><span class="cx">                 }
</span><span class="lines">@@ -628,7 +628,7 @@
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="cx">                 if (!strcasecmp(action, "delete")) {
</span><del>-                        if (switch_strlen_zero(header_val)) {
</del><ins>+                        if (zstr(header_val)) {
</ins><span class="cx">                                 stream->write_function(stream, "<data><reply type=\"error\">Invalid Syntax</reply></data>\n");
</span><span class="cx">                                 goto filter_end;
</span><span class="cx">                         }
</span><span class="lines">@@ -641,7 +641,7 @@
</span><span class="cx">                         }
</span><span class="cx">                         stream->write_function(stream, "<data>\n <reply type=\"success\">filter deleted.</reply>\n<api-command>\n");
</span><span class="cx">                 } else if (!strcasecmp(action, "add")) {
</span><del>-                        if (switch_strlen_zero(header_name) || switch_strlen_zero(header_val)) {
</del><ins>+                        if (zstr(header_name) || zstr(header_val)) {
</ins><span class="cx">                                 stream->write_function(stream, "<data><reply type=\"error\">Invalid Syntax</reply></data>\n");
</span><span class="cx">                                 goto filter_end;
</span><span class="cx">                         }
</span><span class="lines">@@ -715,7 +715,7 @@
</span><span class="cx">                 uint8_t custom = 0;
</span><span class="cx">                 char *edup;
</span><span class="cx">                 
</span><del>-                if (switch_strlen_zero(events) && switch_strlen_zero(loglevel)) {
</del><ins>+                if (zstr(events) && zstr(loglevel)) {
</ins><span class="cx">                         stream->write_function(stream, "<data><reply type=\"error\">Missing parameter!</reply></data>\n");
</span><span class="cx">                         goto end;
</span><span class="cx">                 }
</span><span class="lines">@@ -1068,7 +1068,7 @@
</span><span class="cx">                                                 char *var, *val;
</span><span class="cx">                                                 var = cur;
</span><span class="cx">                                                 strip_cr(var);
</span><del>-                                                if (!switch_strlen_zero(var)) {
</del><ins>+                                                if (!zstr(var)) {
</ins><span class="cx">                                                         if ((val = strchr(var, ':'))) {
</span><span class="cx">                                                                 *val++ = '\0';
</span><span class="cx">                                                                 while (*val == ' ') {
</span><span class="lines">@@ -1583,7 +1583,7 @@
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(onoff)) {
</del><ins>+                if (zstr(onoff)) {
</ins><span class="cx">                         switch_snprintf(reply, reply_len, "-ERR missing value.");
</span><span class="cx">                         goto done;
</span><span class="cx">                 }
</span><span class="lines">@@ -1623,7 +1623,7 @@
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="cx">                 
</span><del>-                if (switch_strlen_zero(uuid)) {
</del><ins>+                if (zstr(uuid)) {
</ins><span class="cx">                         uuid = switch_event_get_header(*event, "session-id");
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -1631,7 +1631,7 @@
</span><span class="cx">                         uuid = NULL;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(uuid) && listener->session) {
</del><ins>+                if (zstr(uuid) && listener->session) {
</ins><span class="cx">                         if (async) {
</span><span class="cx">                                 if ((status = switch_core_session_queue_private_event(listener->session, event)) == SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                                         switch_snprintf(reply, reply_len, "+OK");
</span><span class="lines">@@ -1643,7 +1643,7 @@
</span><span class="cx">                                 switch_snprintf(reply, reply_len, "+OK");
</span><span class="cx">                         }
</span><span class="cx">                 } else {
</span><del>-                        if (!switch_strlen_zero(uuid) && (session = switch_core_session_locate(uuid))) {
</del><ins>+                        if (!zstr(uuid) && (session = switch_core_session_locate(uuid))) {
</ins><span class="cx">                                 if ((status = switch_core_session_queue_private_event(session, event)) == SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                                         switch_snprintf(reply, reply_len, "+OK");
</span><span class="cx">                                 } else {
</span><span class="lines">@@ -1789,12 +1789,12 @@
</span><span class="cx">                 level_s = cmd + 3;
</span><span class="cx">
</span><span class="cx">                 //see if we got an argument
</span><del>-                if (!switch_strlen_zero(level_s)) {
</del><ins>+                if (!zstr(level_s)) {
</ins><span class="cx">                         //if so move to the argument
</span><span class="cx">                         level_s++;
</span><span class="cx">                 }
</span><span class="cx">                 //see if we lined up on an argument or not
</span><del>-                if (!switch_strlen_zero(level_s)) {
</del><ins>+                if (!zstr(level_s)) {
</ins><span class="cx">                         ltype = switch_log_str2level(level_s);
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -1961,7 +1961,7 @@
</span><span class="cx">
</span><span class="cx"> done:
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(reply)) {
</del><ins>+        if (zstr(reply)) {
</ins><span class="cx">                 switch_snprintf(reply, reply_len, "-ERR command not found");
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2003,7 +2003,7 @@
</span><span class="cx">         switch_socket_opt_set(listener->sock, SWITCH_SO_TCP_NODELAY, TRUE);
</span><span class="cx">         switch_socket_opt_set(listener->sock, SWITCH_SO_NONBLOCK, TRUE);
</span><span class="cx">
</span><del>-        if (prefs.acl_count && listener->sa && !switch_strlen_zero(listener->remote_ip)) {
</del><ins>+        if (prefs.acl_count && listener->sa && !zstr(listener->remote_ip)) {
</ins><span class="cx">                 uint32_t x = 0;
</span><span class="cx">
</span><span class="cx">                 for (x = 0; x < prefs.acl_count; x++) {
</span><span class="lines">@@ -2024,7 +2024,7 @@
</span><span class="cx">         }
</span><span class="cx">         
</span><span class="cx">         if (globals.debug > 0) {
</span><del>-                if (switch_strlen_zero(listener->remote_ip)) {
</del><ins>+                if (zstr(listener->remote_ip)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Connection Open\n");
</span><span class="cx">                 } else {
</span><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Connection Open from %s:%d\n", listener->remote_ip, listener->remote_port);
</span><span class="lines">@@ -2243,11 +2243,11 @@
</span><span class="cx">                 switch_xml_free(xml);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(prefs.ip)) {
</del><ins>+        if (zstr(prefs.ip)) {
</ins><span class="cx">                 set_pref_ip("127.0.0.1");
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(prefs.password)) {
</del><ins>+        if (zstr(prefs.password)) {
</ins><span class="cx">                 set_pref_pass("ClueCon");
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodformatsmod_local_streammod_local_streamc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/formats/mod_local_stream/mod_local_stream.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/formats/mod_local_stream/mod_local_stream.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/formats/mod_local_stream/mod_local_stream.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -608,7 +608,7 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -621,7 +621,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         local_stream_name = argv[0];
</span><del>-        if (switch_strlen_zero(local_stream_name)) {
</del><ins>+        if (zstr(local_stream_name)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -662,7 +662,7 @@
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.mutex);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 for (hi = switch_hash_first(NULL, globals.source_hash); hi; hi = switch_hash_next(hi)) {
</span><span class="cx">                         switch_hash_this(hi, &var, NULL, &val);
</span><span class="cx">                         if ((source = (local_stream_source_t *) val)) {
</span><span class="lines">@@ -751,7 +751,7 @@
</span><span class="cx">         switch_xml_t cfg, xml, directory, param;
</span><span class="cx">         int tmp;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -855,7 +855,7 @@
</span><span class="cx">                 switch_xml_free(xml);
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(local_stream_name) || switch_strlen_zero(path)) {
</del><ins>+        if (zstr(local_stream_name) || zstr(path)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodformatsmod_portaudio_streammod_portaudio_streamc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/formats/mod_portaudio_stream/mod_portaudio_stream.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/formats/mod_portaudio_stream/mod_portaudio_stream.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/formats/mod_portaudio_stream/mod_portaudio_stream.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -136,7 +136,7 @@
</span><span class="cx">                 int match = 0;
</span><span class="cx">                 pdi = Pa_GetDeviceInfo(i);
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(name)) {
</del><ins>+                if (zstr(name)) {
</ins><span class="cx">                         match = 1;
</span><span class="cx">                 } else if (pdi && pdi->name && strstr(pdi->name, name)) {
</span><span class="cx">                         match = 1;
</span></span></pre></div>
<a id="freeswitchtrunksrcmodlanguagesmod_luafreeswitch_luacpp"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/languages/mod_lua/freeswitch_lua.cpp (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/languages/mod_lua/freeswitch_lua.cpp        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/languages/mod_lua/freeswitch_lua.cpp        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -140,7 +140,7 @@
</span><span class="cx">                 lua_call(L, arg_count, 1);
</span><span class="cx">                 err = lua_tostring(L, -1);
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(err)) {
</del><ins>+                if (!zstr(err)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "%s\n", err);
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -198,7 +198,7 @@
</span><span class="cx">
</span><span class="cx">         if (func) {
</span><span class="cx">                 hangup_func_str = strdup(func);
</span><del>-                if (!switch_strlen_zero(arg)) {
</del><ins>+                if (!zstr(arg)) {
</ins><span class="cx">                         hangup_func_arg = strdup(arg);
</span><span class="cx">                 }
</span><span class="cx">                 switch_channel_set_private(channel, "CoreSession", this);
</span><span class="lines">@@ -269,7 +269,7 @@
</span><span class="cx">                         lua_pushnumber(L, dtmf->duration);
</span><span class="cx">                         lua_rawset(L, -3);
</span><span class="cx">
</span><del>-                        if (!switch_strlen_zero(cb_arg)) {
</del><ins>+                        if (!zstr(cb_arg)) {
</ins><span class="cx">                                 lua_getfield(L, LUA_GLOBALSINDEX, (char *) cb_arg);
</span><span class="cx">                                 arg_count++;
</span><span class="cx">                         }
</span><span class="lines">@@ -293,7 +293,7 @@
</span><span class="cx">                         mod_lua_conjure_event(L, event, "__Input_Event__", 1);
</span><span class="cx">                         lua_getfield(L, LUA_GLOBALSINDEX, "__Input_Event__");
</span><span class="cx">
</span><del>-                        if (!switch_strlen_zero(cb_arg)) {
</del><ins>+                        if (!zstr(cb_arg)) {
</ins><span class="cx">                                 lua_getfield(L, LUA_GLOBALSINDEX, (char *) cb_arg);
</span><span class="cx">                                 arg_count++;
</span><span class="cx">                         }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodlanguagesmod_luamod_luacpp"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/languages/mod_lua/mod_lua.cpp (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/languages/mod_lua/mod_lua.cpp        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/languages/mod_lua/mod_lua.cpp        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -121,7 +121,7 @@
</span><span class="cx"> {
</span><span class="cx">         int error = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(input_code)) {
</del><ins>+        if (zstr(input_code)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "No code to execute!\n");
</span><span class="cx">                 return 1;
</span><span class="cx">         }
</span><span class="lines">@@ -178,7 +178,7 @@
</span><span class="cx">
</span><span class="cx">         if (error) {
</span><span class="cx">                 const char *err = lua_tostring(L, -1);
</span><del>-                if (!switch_strlen_zero(err)) {
</del><ins>+                if (!zstr(err)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "%s\n", err);
</span><span class="cx">                 }
</span><span class="cx">                 lua_pop(L, 1);                        /* pop error message from the stack */
</span><span class="lines">@@ -216,7 +216,7 @@
</span><span class="cx">
</span><span class="cx">         switch_xml_t xml = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(globals.xml_handler)) {
</del><ins>+        if (!zstr(globals.xml_handler)) {
</ins><span class="cx">                 lua_State *L = lua_init();
</span><span class="cx">                 char *mycmd = strdup(globals.xml_handler);
</span><span class="cx">                 const char *str;
</span><span class="lines">@@ -253,7 +253,7 @@
</span><span class="cx">                 str = lua_tostring(L, 1);
</span><span class="cx">                 
</span><span class="cx">                 if (str) {
</span><del>-                        if (switch_strlen_zero(str)) {
</del><ins>+                        if (zstr(str)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "No Result\n");
</span><span class="cx">                         } else if (!(xml = switch_xml_parse_str_dynamic((char *)str, SWITCH_TRUE))) {
</span><span class="cx">                                 /* const char -> char conversion was OK because switch_xml_parse_str_dynamic makes a duplicate of str
</span><span class="lines">@@ -293,17 +293,17 @@
</span><span class="cx">                         if (!strcmp(var, "xml-handler-script")) {
</span><span class="cx">                                 globals.xml_handler = switch_core_strdup(globals.pool, val);
</span><span class="cx">                         } else if (!strcmp(var, "xml-handler-bindings")) {
</span><del>-                                if (!switch_strlen_zero(globals.xml_handler)) {
</del><ins>+                                if (!zstr(globals.xml_handler)) {
</ins><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "binding '%s' to '%s'\n", globals.xml_handler, val);
</span><span class="cx">                                         switch_xml_bind_search_function(lua_fetch, switch_xml_parse_section_string(val), NULL);
</span><span class="cx">                                 }
</span><del>-                        } else if (!strcmp(var, "module-directory") && !switch_strlen_zero(val)) {
</del><ins>+                        } else if (!strcmp(var, "module-directory") && !zstr(val)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "lua: appending module directory: '%s'\n", val);
</span><span class="cx">                                 if (cpath_stream.data_len) {
</span><span class="cx">                                         cpath_stream.write_function(&cpath_stream, ";");
</span><span class="cx">                                 }
</span><span class="cx">                                 cpath_stream.write_function(&cpath_stream, "%s", val);
</span><del>-                        } else if (!strcmp(var, "script-directory") && !switch_strlen_zero(val)) {
</del><ins>+                        } else if (!strcmp(var, "script-directory") && !zstr(val)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "lua: appending script directory: '%s'\n", val);
</span><span class="cx">                                 if (path_stream.data_len) {
</span><span class="cx">                                         path_stream.write_function(&path_stream, ";");
</span><span class="lines">@@ -394,7 +394,7 @@
</span><span class="cx">         char *mycmd;
</span><span class="cx">         int error;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "no args specified!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -413,7 +413,7 @@
</span><span class="cx"> SWITCH_STANDARD_API(luarun_api_function)
</span><span class="cx"> {
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR no args specified!\n");
</span><span class="cx">         } else {
</span><span class="cx">                 lua_thread(cmd);
</span><span class="lines">@@ -431,7 +431,7 @@
</span><span class="cx">         char *mycmd;
</span><span class="cx">         int error;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "");
</span><span class="cx">         } else {
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodlanguagesmod_managedmod_managedcpp"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/languages/mod_managed/mod_managed.cpp (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/languages/mod_managed/mod_managed.cpp        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/languages/mod_managed/mod_managed.cpp        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -371,7 +371,7 @@
</span><span class="cx"> #endif
</span><span class="cx"> SWITCH_STANDARD_API(managedrun_api_function)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR no args specified!\n");        
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -391,7 +391,7 @@
</span><span class="cx">
</span><span class="cx"> SWITCH_STANDARD_API(managed_api_function)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR no args specified!\n");        
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -409,7 +409,7 @@
</span><span class="cx">
</span><span class="cx"> SWITCH_STANDARD_APP(managed_app_function)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "No args specified!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -426,7 +426,7 @@
</span><span class="cx">
</span><span class="cx"> SWITCH_STANDARD_API(managedreload_api_function)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR no args specified!\n");        
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodlanguagesmod_perlmod_perlc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/languages/mod_perl/mod_perl.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/languages/mod_perl/mod_perl.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/languages/mod_perl/mod_perl.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -64,7 +64,7 @@
</span><span class="cx">
</span><span class="cx">         Perl_eval_pv(my_perl, string, FALSE);
</span><span class="cx">
</span><del>-        if ((err = SvPV(get_sv("@", TRUE), n_a)) && !switch_strlen_zero(err)) {
</del><ins>+        if ((err = SvPV(get_sv("@", TRUE), n_a)) && !zstr(err)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "[%s]\n%s\n", string, err);
</span><span class="cx">                 return -1;
</span><span class="cx">         }
</span><span class="lines">@@ -77,7 +77,7 @@
</span><span class="cx"> {
</span><span class="cx">         int error = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(input_code)) {
</del><ins>+        if (zstr(input_code)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "No code to execute!\n");
</span><span class="cx">                 return -1;
</span><span class="cx">         }
</span><span class="lines">@@ -183,7 +183,7 @@
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if ((err = SvPV(get_sv("@", TRUE), n_a)) && !switch_strlen_zero(err)) {
</del><ins>+                if ((err = SvPV(get_sv("@", TRUE), n_a)) && !zstr(err)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "%s\n", err);
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -304,7 +304,7 @@
</span><span class="cx"> SWITCH_STANDARD_API(perlrun_api_function)
</span><span class="cx"> {
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR Missing args.\n");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -319,7 +319,7 @@
</span><span class="cx">
</span><span class="cx">         struct perl_o po = { 0 };
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "-ERR Missing args.\n");
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -338,7 +338,7 @@
</span><span class="cx">         int argc = 0;
</span><span class="cx">         switch_xml_t xml = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(globals.xml_handler)) {
</del><ins>+        if (!zstr(globals.xml_handler)) {
</ins><span class="cx">                 PerlInterpreter *my_perl = clone_perl();
</span><span class="cx">                 HV *hash;
</span><span class="cx">                 char *str;
</span><span class="lines">@@ -360,7 +360,7 @@
</span><span class="cx">                         abort();
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(section)) {
</del><ins>+                if (zstr(section)) {
</ins><span class="cx">                         section = "";
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -368,7 +368,7 @@
</span><span class="cx">                 sv_setpv(this, section);
</span><span class="cx">                 hv_store(hash, "section", 7, this, 0);
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(tag_name)) {
</del><ins>+                if (zstr(tag_name)) {
</ins><span class="cx">                         tag_name = "";
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -376,7 +376,7 @@
</span><span class="cx">                 sv_setpv(this, tag_name);
</span><span class="cx">                 hv_store(hash, "tag_name", 8, this, 0);
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(key_name)) {
</del><ins>+                if (zstr(key_name)) {
</ins><span class="cx">                         key_name = "";
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -384,7 +384,7 @@
</span><span class="cx">                 sv_setpv(this, key_name);
</span><span class="cx">                 hv_store(hash, "key_name", 8, this, 0);
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(key_value)) {
</del><ins>+                if (zstr(key_value)) {
</ins><span class="cx">                         key_value = "";
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -414,8 +414,8 @@
</span><span class="cx">                 perl_run(my_perl);
</span><span class="cx">                 str = SvPV(get_sv("XML_STRING", TRUE), n_a);
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(str)) {
-                        if (switch_strlen_zero(str)) {
</del><ins>+                if (!zstr(str)) {
+                        if (zstr(str)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "No Result\n");
</span><span class="cx">                         } else if (!(xml = switch_xml_parse_str(str, strlen(str)))) {
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Parsing XML Result!\n");
</span><span class="lines">@@ -446,7 +446,7 @@
</span><span class="cx">                         if (!strcmp(var, "xml-handler-script")) {
</span><span class="cx">                                 globals.xml_handler = switch_core_strdup(globals.pool, val);
</span><span class="cx">                         } else if (!strcmp(var, "xml-handler-bindings")) {
</span><del>-                                if (!switch_strlen_zero(globals.xml_handler)) {
</del><ins>+                                if (!zstr(globals.xml_handler)) {
</ins><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "binding '%s' to '%s'\n", globals.xml_handler, var);
</span><span class="cx">                                         switch_xml_bind_search_function(perl_fetch, switch_xml_parse_section_string(val), NULL);
</span><span class="cx">                                 }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodlanguagesmod_pythonmod_pythonc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/languages/mod_python/mod_python.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/languages/mod_python/mod_python.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/languages/mod_python/mod_python.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -236,7 +236,7 @@
</span><span class="cx">         switch_xml_t xml = NULL;
</span><span class="cx">         char *str = NULL;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(globals.xml_handler)) {
</del><ins>+        if (!zstr(globals.xml_handler)) {
</ins><span class="cx">                 char *mycmd = strdup(globals.xml_handler);
</span><span class="cx">
</span><span class="cx">                 switch_assert(mycmd);
</span><span class="lines">@@ -244,7 +244,7 @@
</span><span class="cx">                 eval_some_python("xml_fetch", mycmd, NULL, NULL, params, &str, NULL);
</span><span class="cx">
</span><span class="cx">                 if (str) {
</span><del>-                        if (switch_strlen_zero(str)) {
</del><ins>+                        if (zstr(str)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "No Result\n");
</span><span class="cx">                         } else if (!(xml = switch_xml_parse_str((char *) str, strlen(str)))) {
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Parsing XML Result!\n");
</span><span class="lines">@@ -276,7 +276,7 @@
</span><span class="cx">                         if (!strcmp(var, "xml-handler-script")) {
</span><span class="cx">                                 globals.xml_handler = switch_core_strdup(globals.pool, val);
</span><span class="cx">                         } else if (!strcmp(var, "xml-handler-bindings")) {
</span><del>-                                if (!switch_strlen_zero(globals.xml_handler)) {
</del><ins>+                                if (!zstr(globals.xml_handler)) {
</ins><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "binding '%s' to '%s'\n", globals.xml_handler, val);
</span><span class="cx">                                         switch_xml_bind_search_function(python_fetch, switch_xml_parse_section_string(val), NULL);
</span><span class="cx">                                 }
</span><span class="lines">@@ -397,7 +397,7 @@
</span><span class="cx"> SWITCH_STANDARD_API(launch_python)
</span><span class="cx"> {
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "USAGE: %s\n", python_run_interface.syntax);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodlanguagesmod_spidermonkeymod_spidermonkeyc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -1015,7 +1015,7 @@
</span><span class="cx">                 if ((mods = switch_xml_child(cfg, "modules"))) {
</span><span class="cx">                         for (ld = switch_xml_child(mods, "load"); ld; ld = ld->next) {
</span><span class="cx">                                 const char *val = switch_xml_attr_soft(ld, "module");
</span><del>-                                if (!switch_strlen_zero(val) && strchr(val, '.') && !strstr(val, ext) && !strstr(val, EXT)) {
</del><ins>+                                if (!zstr(val) && strchr(val, '.') && !strstr(val, ext) && !strstr(val, EXT)) {
</ins><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "Invalid extension for %s\n", val);
</span><span class="cx">                                         continue;
</span><span class="cx">                                 }
</span><span class="lines">@@ -1405,7 +1405,7 @@
</span><span class="cx">
</span><span class="cx">         if (argc > 0) {
</span><span class="cx">                 file_name = JS_GetStringBytes(JS_ValueToString(cx, argv[0]));
</span><del>-                if (switch_strlen_zero(file_name)) {
</del><ins>+                if (zstr(file_name)) {
</ins><span class="cx">                         return JS_FALSE;
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="lines">@@ -1542,7 +1542,7 @@
</span><span class="cx">
</span><span class="cx">         if (argc > 0) {
</span><span class="cx">                 phrase_name = JS_GetStringBytes(JS_ValueToString(cx, argv[0]));
</span><del>-                if (switch_strlen_zero(phrase_name)) {
</del><ins>+                if (zstr(phrase_name)) {
</ins><span class="cx">                         return JS_FALSE;
</span><span class="cx">                 }
</span><span class="cx">         } else {
</span><span class="lines">@@ -1555,7 +1555,7 @@
</span><span class="cx">
</span><span class="cx">         if (argc > 2) {
</span><span class="cx">                 tmp = JS_GetStringBytes(JS_ValueToString(cx, argv[2]));
</span><del>-                if (!switch_strlen_zero(tmp)) {
</del><ins>+                if (!zstr(tmp)) {
</ins><span class="cx">                         phrase_lang = tmp;
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="lines">@@ -1609,7 +1609,7 @@
</span><span class="cx">                 }
</span><span class="cx">                 JS_CallFunction(jss->cx, jss->obj, jss->on_hangup, argc, argv, &ret);
</span><span class="cx">                 resp = JS_GetStringBytes(JS_ValueToString(jss->cx, ret));
</span><del>-                if (!switch_strlen_zero(resp)) {
</del><ins>+                if (!zstr(resp)) {
</ins><span class="cx">                         ret = !strcasecmp(resp, "exit") ? JS_FALSE : JS_TRUE;
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="lines">@@ -1683,7 +1683,7 @@
</span><span class="cx">
</span><span class="cx">         if (argc > 0) {
</span><span class="cx">                 file_name = JS_GetStringBytes(JS_ValueToString(cx, argv[0]));
</span><del>-                if (switch_strlen_zero(file_name)) {
</del><ins>+                if (zstr(file_name)) {
</ins><span class="cx">                         return JS_FALSE;
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="lines">@@ -1927,12 +1927,12 @@
</span><span class="cx">         voice_name = JS_GetStringBytes(JS_ValueToString(cx, argv[1]));
</span><span class="cx">         text = JS_GetStringBytes(JS_ValueToString(cx, argv[2]));
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(tts_name)) {
</del><ins>+        if (zstr(tts_name)) {
</ins><span class="cx">                 eval_some_js("~throw new Error(\"Invalid TTS Name\");", cx, obj, rval);
</span><span class="cx">                 return JS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(text)) {
</del><ins>+        if (zstr(text)) {
</ins><span class="cx">                 eval_some_js("~throw new Error(\"Invalid Text\");", cx, obj, rval);
</span><span class="cx">                 return JS_FALSE;
</span><span class="cx">         }
</span><span class="lines">@@ -2972,21 +2972,21 @@
</span><span class="cx">
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(jss->dialplan))
</del><ins>+                if (!zstr(jss->dialplan))
</ins><span class="cx">                         dialplan = jss->dialplan;
</span><del>-                if (!switch_strlen_zero(jss->caller_id_name))
</del><ins>+                if (!zstr(jss->caller_id_name))
</ins><span class="cx">                         cid_name = jss->caller_id_name;
</span><del>-                if (!switch_strlen_zero(jss->caller_id_number))
</del><ins>+                if (!zstr(jss->caller_id_number))
</ins><span class="cx">                         cid_num = jss->caller_id_number;
</span><del>-                if (!switch_strlen_zero(jss->ani))
</del><ins>+                if (!zstr(jss->ani))
</ins><span class="cx">                         ani = jss->ani;
</span><del>-                if (!switch_strlen_zero(jss->aniii))
</del><ins>+                if (!zstr(jss->aniii))
</ins><span class="cx">                         aniii = jss->aniii;
</span><del>-                if (!switch_strlen_zero(jss->rdnis))
</del><ins>+                if (!zstr(jss->rdnis))
</ins><span class="cx">                         rdnis = jss->rdnis;
</span><del>-                if (!switch_strlen_zero(jss->context))
</del><ins>+                if (!zstr(jss->context))
</ins><span class="cx">                         context = jss->context;
</span><del>-                if (!switch_strlen_zero(jss->username))
</del><ins>+                if (!zstr(jss->username))
</ins><span class="cx">                         username = jss->username;
</span><span class="cx">
</span><span class="cx">                 dest = JS_GetStringBytes(JS_ValueToString(cx, argv[1]));
</span><span class="lines">@@ -2998,7 +2998,7 @@
</span><span class="cx">
</span><span class="cx">                 if (argc > 2) {
</span><span class="cx">                         tmp = JS_GetStringBytes(JS_ValueToString(cx, argv[2]));
</span><del>-                        if (!switch_strlen_zero(tmp)) {
</del><ins>+                        if (!zstr(tmp)) {
</ins><span class="cx">                                 to = tmp;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="lines">@@ -3678,7 +3678,7 @@
</span><span class="cx">         struct js_task *task;
</span><span class="cx">         switch_memory_pool_t *pool;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(text)) {
</del><ins>+        if (zstr(text)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "missing required input!\n");
</span><span class="cx">                 return;
</span><span class="cx">         }
</span><span class="lines">@@ -3707,11 +3707,11 @@
</span><span class="cx">                 path_info = switch_event_get_header(stream->param_event, "http-path-info");
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd) && path_info) {
</del><ins>+        if (zstr(cmd) && path_info) {
</ins><span class="cx">                 cmd = path_info;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "USAGE: %s\n", jsapi_interface->syntax);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span><span class="lines">@@ -3727,7 +3727,7 @@
</span><span class="cx">
</span><span class="cx"> SWITCH_STANDARD_API(launch_async)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "USAGE: %s\n", js_run_interface->syntax);
</span><span class="cx">                 return SWITCH_STATUS_SUCCESS;
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodlanguagesmod_spidermonkey_curlmod_spidermonkey_curlc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/languages/mod_spidermonkey_curl/mod_spidermonkey_curl.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/languages/mod_spidermonkey_curl/mod_spidermonkey_curl.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/languages/mod_spidermonkey_curl/mod_spidermonkey_curl.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -144,7 +144,7 @@
</span><span class="cx">
</span><span class="cx">         if (argc > 5) {
</span><span class="cx">                 cred = JS_GetStringBytes(JS_ValueToString(cx, argv[5]));
</span><del>-                if (!switch_strlen_zero(cred)) {
</del><ins>+                if (!zstr(cred)) {
</ins><span class="cx">                         curl_easy_setopt(co->curl_handle, CURLOPT_HTTPAUTH, CURLAUTH_ANY);
</span><span class="cx">                         curl_easy_setopt(co->curl_handle, CURLOPT_USERPWD, cred);
</span><span class="cx">                 }
</span><span class="lines">@@ -174,7 +174,7 @@
</span><span class="cx">                         data = "";
</span><span class="cx">                 }
</span><span class="cx">                 curl_easy_setopt(co->curl_handle, CURLOPT_POSTFIELDS, data);
</span><del>-        } else if (!switch_strlen_zero(data)) {
</del><ins>+        } else if (!zstr(data)) {
</ins><span class="cx">                 durl = switch_mprintf("%s?%s", url, data);
</span><span class="cx">                 url_p = durl;
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodlanguagesmod_spidermonkey_odbcmod_spidermonkey_odbcc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/languages/mod_spidermonkey_odbc/mod_spidermonkey_odbc.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/languages/mod_spidermonkey_odbc/mod_spidermonkey_odbc.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/languages/mod_spidermonkey_odbc/mod_spidermonkey_odbc.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -128,11 +128,11 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(username)) {
</del><ins>+        if (zstr(username)) {
</ins><span class="cx">                 username = NULL;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(password)) {
</del><ins>+        if (zstr(password)) {
</ins><span class="cx">                 password = NULL;
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodlanguagesmod_yamlmod_yamlc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/languages/mod_yaml/mod_yaml.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/languages/mod_yaml/mod_yaml.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/languages/mod_yaml/mod_yaml.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -404,7 +404,7 @@
</span><span class="cx">         char *path = NULL;
</span><span class="cx">         FILE *input;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(alt_path)) {
</del><ins>+        if (!zstr(alt_path)) {
</ins><span class="cx">                 path = strdup(alt_path);
</span><span class="cx">         } else {
</span><span class="cx">                 path = switch_mprintf("%s/yaml/extensions.yaml", SWITCH_GLOBAL_dirs.conf_dir);
</span></span></pre></div>
<a id="freeswitchtrunksrcmodloggersmod_consolemod_consolec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/loggers/mod_console/mod_console.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/loggers/mod_console/mod_console.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/loggers/mod_console/mod_console.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -130,7 +130,7 @@
</span><span class="cx"> #else
</span><span class="cx">                                 COLORIZE = 1;
</span><span class="cx"> #endif
</span><del>-                        } else if (!strcasecmp(var, "loglevel") && !switch_strlen_zero(val)) {
</del><ins>+                        } else if (!strcasecmp(var, "loglevel") && !zstr(val)) {
</ins><span class="cx">                                 hard_log_level = switch_log_str2level(val);
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="lines">@@ -289,7 +289,7 @@
</span><span class="cx">         if (session)
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 stream->write_function(stream, "%s", usage_string);
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcmodloggersmod_logfilemod_logfilec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/loggers/mod_logfile/mod_logfile.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/loggers/mod_logfile/mod_logfile.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/loggers/mod_logfile/mod_logfile.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -277,7 +277,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(new_profile->logfile)) {
</del><ins>+        if (zstr(new_profile->logfile)) {
</ins><span class="cx">                 char logfile[512];
</span><span class="cx">                 switch_snprintf(logfile, sizeof(logfile), "%s%s%s", SWITCH_GLOBAL_dirs.log_dir, SWITCH_PATH_SEPARATOR, "freeswitch.log");
</span><span class="cx">                 new_profile->logfile = strdup(logfile);
</span></span></pre></div>
<a id="freeswitchtrunksrcmodloggersmod_syslogmod_syslogc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/loggers/mod_syslog/mod_syslog.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/loggers/mod_syslog/mod_syslog.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/loggers/mod_syslog/mod_syslog.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -101,7 +101,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         /* don't log blank lines */
</span><del>-        if (!switch_strlen_zero(node->data) && (strspn(node->data, " \t\r\n") < strlen(node->data))) {
</del><ins>+        if (!zstr(node->data) && (strspn(node->data, " \t\r\n") < strlen(node->data))) {
</ins><span class="cx">                 syslog(syslog_level, "%s", node->data);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -130,7 +130,7 @@
</span><span class="cx">                                         set_global_format(val);
</span><span class="cx">                                 } else if (!strcmp(var, "facility")) {
</span><span class="cx">                                         set_global_facility(val);
</span><del>- } else if (!strcasecmp(var, "loglevel") && !switch_strlen_zero(val)) {
</del><ins>+ } else if (!strcasecmp(var, "loglevel") && !zstr(val)) {
</ins><span class="cx"> log_level = switch_log_str2level(val);
</span><span class="cx"> if (log_level == SWITCH_LOG_INVALID) {
</span><span class="cx"> log_level = SWITCH_LOG_WARNING;
</span><span class="lines">@@ -142,13 +142,13 @@
</span><span class="cx">                 switch_xml_free(xml);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(globals.ident)) {
</del><ins>+        if (zstr(globals.ident)) {
</ins><span class="cx">                 set_global_ident(DEFAULT_IDENT);
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(globals.format)) {
</del><ins>+        if (zstr(globals.format)) {
</ins><span class="cx">                 set_global_format(DEFAULT_FORMAT);
</span><span class="cx">         }
</span><del>- if (switch_strlen_zero(globals.facility)) {
</del><ins>+ if (zstr(globals.facility)) {
</ins><span class="cx">                 set_global_facility(DEFAULT_FACILITY);
</span><span class="cx"> }
</span><span class="cx">         return 0;
</span></span></pre></div>
<a id="freeswitchtrunksrcmodxml_intmod_xml_cdrmod_xml_cdrc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -89,7 +89,7 @@
</span><span class="cx">
</span><span class="cx">         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Rotating log file paths\n");
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(globals.base_log_dir)) {
</del><ins>+        if (!zstr(globals.base_log_dir)) {
</ins><span class="cx">                 if (globals.rotate) {
</span><span class="cx">                         if ((path = switch_mprintf("%s%s%s", globals.base_log_dir, SWITCH_PATH_SEPARATOR, date))) {
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Rotating log file path to %s\n", path);
</span><span class="lines">@@ -131,7 +131,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(globals.base_err_log_dir)) {
</del><ins>+        if (!zstr(globals.base_err_log_dir)) {
</ins><span class="cx">                 if (globals.rotate) {
</span><span class="cx">                         if ((path = switch_mprintf("%s%s%s", globals.base_err_log_dir, SWITCH_PATH_SEPARATOR, date))) {
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Rotating err log file path to %s\n", path);
</span><span class="lines">@@ -223,7 +223,7 @@
</span><span class="cx">                 logdir = globals.log_dir;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(logdir)) {
</del><ins>+        if (!zstr(logdir)) {
</ins><span class="cx">                 path = switch_mprintf("%s%s%s%s.cdr.xml", logdir, SWITCH_PATH_SEPARATOR, a_prefix, switch_core_session_get_uuid(session));
</span><span class="cx">                 switch_thread_rwlock_unlock(globals.log_path_lock);
</span><span class="cx">                 if (path) {
</span><span class="lines">@@ -280,7 +280,7 @@
</span><span class="cx">                         goto error;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(globals.cred)) {
</del><ins>+                if (!zstr(globals.cred)) {
</ins><span class="cx">                         curl_easy_setopt(curl_handle, CURLOPT_HTTPAUTH, CURLAUTH_ANY);
</span><span class="cx">                         curl_easy_setopt(curl_handle, CURLOPT_USERPWD, globals.cred);
</span><span class="cx">                 }
</span><span class="lines">@@ -474,15 +474,15 @@
</span><span class="cx">                         char *var = (char *) switch_xml_attr_soft(param, "name");
</span><span class="cx">                         char *val = (char *) switch_xml_attr_soft(param, "value");
</span><span class="cx">
</span><del>-                        if (!strcasecmp(var, "cred") && !switch_strlen_zero(val)) {
</del><ins>+                        if (!strcasecmp(var, "cred") && !zstr(val)) {
</ins><span class="cx">                                 globals.cred = switch_core_strdup(globals.pool, val);
</span><del>-                        } else if (!strcasecmp(var, "url") && !switch_strlen_zero(val)) {
</del><ins>+                        } else if (!strcasecmp(var, "url") && !zstr(val)) {
</ins><span class="cx">                                 if (globals.url_count >= MAX_URLS) {
</span><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "maximum urls configured!\n");
</span><span class="cx">                                 } else {
</span><span class="cx">                                         globals.urls[globals.url_count++] = switch_core_strdup(globals.pool, val);
</span><span class="cx">                                 }
</span><del>-                        } else if (!strcasecmp(var, "delay") && !switch_strlen_zero(val)) {
</del><ins>+                        } else if (!strcasecmp(var, "delay") && !zstr(val)) {
</ins><span class="cx">                                 globals.delay = (uint32_t) atoi(val);
</span><span class="cx">                         } else if (!strcasecmp(var, "log-b-leg")) {
</span><span class="cx">                                 globals.log_b = switch_true(val);
</span><span class="lines">@@ -490,18 +490,18 @@
</span><span class="cx">                                 globals.prefix_a = switch_true(val);
</span><span class="cx">                         } else if (!strcasecmp(var, "disable-100-continue") && switch_true(val)) {
</span><span class="cx">                                 globals.disable100continue = 1;
</span><del>-                        } else if (!strcasecmp(var, "encode") && !switch_strlen_zero(val)) {
</del><ins>+                        } else if (!strcasecmp(var, "encode") && !zstr(val)) {
</ins><span class="cx">                                 if (!strcasecmp(val, "base64")) {
</span><span class="cx">                                         globals.encode = 2;
</span><span class="cx">                                 } else {
</span><span class="cx">                                         globals.encode = switch_true(val) ? 1 : 0;
</span><span class="cx">                                 }
</span><del>-                        } else if (!strcasecmp(var, "retries") && !switch_strlen_zero(val)) {
</del><ins>+                        } else if (!strcasecmp(var, "retries") && !zstr(val)) {
</ins><span class="cx">                                 globals.retries = (uint32_t) atoi(val);
</span><del>-                        } else if (!strcasecmp(var, "rotate") && !switch_strlen_zero(val)) {
</del><ins>+                        } else if (!strcasecmp(var, "rotate") && !zstr(val)) {
</ins><span class="cx">                                 globals.rotate = switch_true(val);
</span><span class="cx">                         } else if (!strcasecmp(var, "log-dir")) {
</span><del>-                                if (switch_strlen_zero(val)) {
</del><ins>+                                if (zstr(val)) {
</ins><span class="cx">                                         globals.base_log_dir = switch_mprintf("%s%sxml_cdr", SWITCH_GLOBAL_dirs.log_dir, SWITCH_PATH_SEPARATOR);
</span><span class="cx">                                 } else {
</span><span class="cx">                                         if (switch_is_file_path(val)) {
</span><span class="lines">@@ -511,7 +511,7 @@
</span><span class="cx">                                         }
</span><span class="cx">                                 }
</span><span class="cx">                         } else if (!strcasecmp(var, "err-log-dir")) {
</span><del>-                                if (switch_strlen_zero(val)) {
</del><ins>+                                if (zstr(val)) {
</ins><span class="cx">                                         globals.base_err_log_dir = switch_mprintf("%s%sxml_cdr", SWITCH_GLOBAL_dirs.log_dir, SWITCH_PATH_SEPARATOR);
</span><span class="cx">                                 } else {
</span><span class="cx">                                         if (switch_is_file_path(val)) {
</span><span class="lines">@@ -536,8 +536,8 @@
</span><span class="cx">                                 globals.enable_ssl_verifyhost = 1;
</span><span class="cx">                         }
</span><span class="cx">                 
</span><del>-                        if (switch_strlen_zero(globals.base_err_log_dir)) {
-                                if (!switch_strlen_zero(globals.base_log_dir)) {
</del><ins>+                        if (zstr(globals.base_err_log_dir)) {
+                                if (!zstr(globals.base_log_dir)) {
</ins><span class="cx">                                         globals.base_err_log_dir = switch_core_strdup(globals.pool, globals.base_log_dir);
</span><span class="cx">                                 } else {
</span><span class="cx">                                         globals.base_err_log_dir = switch_core_sprintf(globals.pool, "%s%sxml_cdr", SWITCH_GLOBAL_dirs.log_dir, SWITCH_PATH_SEPARATOR);
</span></span></pre></div>
<a id="freeswitchtrunksrcmodxml_intmod_xml_curlmod_xml_curlc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/xml_int/mod_xml_curl/mod_xml_curl.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/xml_int/mod_xml_curl/mod_xml_curl.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/xml_int/mod_xml_curl/mod_xml_curl.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -90,7 +90,7 @@
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -217,7 +217,7 @@
</span><span class="cx">         config_data.max_bytes = XML_CURL_MAX_BYTES;
</span><span class="cx">
</span><span class="cx">         if ((config_data.fd = open(filename, O_CREAT | O_RDWR | O_TRUNC, S_IRUSR | S_IWUSR)) > -1) {
</span><del>-                if (!switch_strlen_zero(binding->cred)) {
</del><ins>+                if (!zstr(binding->cred)) {
</ins><span class="cx">                         curl_easy_setopt(curl_handle, CURLOPT_HTTPAUTH, binding->auth_scheme);
</span><span class="cx">                         curl_easy_setopt(curl_handle, CURLOPT_USERPWD, binding->cred);
</span><span class="cx">                 }
</span><span class="lines">@@ -508,7 +508,7 @@
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Binding [%s] XML Fetch Function [%s] [%s]\n",
</span><del>-                                                 switch_strlen_zero(bname) ? "N/A" : bname, binding->url, binding->bindings ? binding->bindings : "all");
</del><ins>+                                                 zstr(bname) ? "N/A" : bname, binding->url, binding->bindings ? binding->bindings : "all");
</ins><span class="cx">                 switch_xml_bind_search_function(xml_url_fetch, switch_xml_parse_section_string(binding->bindings), binding);
</span><span class="cx">                 x++;
</span><span class="cx">                 binding = NULL;
</span></span></pre></div>
<a id="freeswitchtrunksrcmodxml_intmod_xml_ldapmod_xml_ldapc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldap.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldap.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldap.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -93,7 +93,7 @@
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 goto usage;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -466,7 +466,7 @@
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Binding [%s] XML Fetch Function [%s] (%s) [%s]\n",
</span><del>-                                                 switch_strlen_zero(bname) ? "N/A" : bname, binding->basedn, binding->filter, binding->bindings ? binding->bindings : "all");
</del><ins>+                                                 zstr(bname) ? "N/A" : bname, binding->basedn, binding->filter, binding->bindings ? binding->bindings : "all");
</ins><span class="cx">
</span><span class="cx">                 switch_xml_bind_search_function(xml_ldap_search, switch_xml_parse_section_string(bname), binding);
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodxml_intmod_xml_ldapmod_xml_ldapv2c"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldapv2.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldapv2.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/xml_int/mod_xml_ldap/mod_xml_ldapv2.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -257,7 +257,7 @@
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Binding [%s] XML Fetch Function [%s] (%s) [%s]\n",
</span><del>-                                                 switch_strlen_zero(bname) ? "N/A" : bname, binding->basedn, binding->filter, binding->bindings ? binding->bindings : "all");
</del><ins>+                                                 zstr(bname) ? "N/A" : bname, binding->basedn, binding->filter, binding->bindings ? binding->bindings : "all");
</ins><span class="cx">
</span><span class="cx">                 switch_xml_bind_search_function(xml_ldap_search, switch_xml_parse_section_string(bname), binding);
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcmodxml_intmod_xml_rpcmod_xml_rpcc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/mod/xml_int/mod_xml_rpc/mod_xml_rpc.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/mod/xml_int/mod_xml_rpc/mod_xml_rpc.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/mod/xml_int/mod_xml_rpc/mod_xml_rpc.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -257,7 +257,7 @@
</span><span class="cx">                 return FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(globals.realm) && switch_strlen_zero(globals.user)) {
</del><ins>+        if (zstr(globals.realm) && zstr(globals.user)) {
</ins><span class="cx">                 return TRUE;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -272,12 +272,12 @@
</span><span class="cx">                 domain_name = dp;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(globals.realm) && !switch_strlen_zero(globals.user) && !strcmp(user, globals.user)) {
</del><ins>+        if (!zstr(globals.realm) && !zstr(globals.user) && !strcmp(user, globals.user)) {
</ins><span class="cx">                 switch_safe_free(user);
</span><span class="cx">                 return TRUE;
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(user) || switch_strlen_zero(domain_name)) {
</del><ins>+        if (zstr(user) || zstr(domain_name)) {
</ins><span class="cx">                 switch_safe_free(user);
</span><span class="cx">                 return FALSE;
</span><span class="cx">         }
</span><span class="lines">@@ -352,11 +352,11 @@
</span><span class="cx">                                         }
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (switch_strlen_zero(user) || switch_strlen_zero(domain_name)) {
</del><ins>+                                if (zstr(user) || zstr(domain_name)) {
</ins><span class="cx">                                         goto fail;
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(globals.realm) && !switch_strlen_zero(globals.user) && !switch_strlen_zero(globals.pass)) {
</del><ins>+                                if (!zstr(globals.realm) && !zstr(globals.user) && !zstr(globals.pass)) {
</ins><span class="cx">                                         if (at) {
</span><span class="cx">                                                 switch_snprintf(z, sizeof(z), "%s@%s:%s", globals.user, globals.realm, globals.pass);
</span><span class="cx">                                         } else {
</span><span class="lines">@@ -374,7 +374,7 @@
</span><span class="cx">                                 }
</span><span class="cx">
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(mypass2) && !strcasecmp(mypass2, "user-choose")) {
</del><ins>+                                if (!zstr(mypass2) && !strcasecmp(mypass2, "user-choose")) {
</ins><span class="cx">                                         mypass2 = NULL;
</span><span class="cx">                                 }
</span><span class="cx">
</span><span class="lines">@@ -872,7 +872,7 @@
</span><span class="cx">                 relative_oid = oid;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 switch_copy_string(buf, data, sizeof(buf));
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_callerc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_caller.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_caller.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_caller.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -33,8 +33,8 @@
</span><span class="cx"> #include <switch.h>
</span><span class="cx"> #include <switch_caller.h>
</span><span class="cx">
</span><del>-#define profile_dup(a,b,p) if (!switch_strlen_zero(a)) { b = switch_core_strdup(p, a); } else { b = SWITCH_BLANK_STRING; }
-#define profile_dup_clean(a,b,p) if (!switch_strlen_zero(a)) { b = switch_var_clean_string(switch_clean_string(switch_core_strdup(p, a)));} else { b = SWITCH_BLANK_STRING; }
</del><ins>+#define profile_dup(a,b,p) if (!zstr(a)) { b = switch_core_strdup(p, a); } else { b = SWITCH_BLANK_STRING; }
+#define profile_dup_clean(a,b,p) if (!zstr(a)) { b = switch_var_clean_string(switch_clean_string(switch_core_strdup(p, a)));} else { b = SWITCH_BLANK_STRING; }
</ins><span class="cx">
</span><span class="cx"> SWITCH_DECLARE(switch_caller_profile_t *) switch_caller_profile_new(switch_memory_pool_t *pool,
</span><span class="cx">                                                                                                                                         const char *username,
</span><span class="lines">@@ -57,11 +57,11 @@
</span><span class="cx">                 context = "default";
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(caller_id_name)) {
</del><ins>+        if (zstr(caller_id_name)) {
</ins><span class="cx">                 caller_id_name = "FreeSWITCH";
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(caller_id_number)) {
</del><ins>+        if (zstr(caller_id_number)) {
</ins><span class="cx">                 caller_id_number = "0000000000";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -247,59 +247,59 @@
</span><span class="cx"> {
</span><span class="cx">         char header_name[1024];
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(caller_profile->username)) {
</del><ins>+        if (!zstr(caller_profile->username)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Username", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->username);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->dialplan)) {
</del><ins>+        if (!zstr(caller_profile->dialplan)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Dialplan", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->dialplan);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->caller_id_name)) {
</del><ins>+        if (!zstr(caller_profile->caller_id_name)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Caller-ID-Name", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->caller_id_name);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->caller_id_number)) {
</del><ins>+        if (!zstr(caller_profile->caller_id_number)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Caller-ID-Number", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->caller_id_number);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->network_addr)) {
</del><ins>+        if (!zstr(caller_profile->network_addr)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Network-Addr", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->network_addr);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->ani)) {
</del><ins>+        if (!zstr(caller_profile->ani)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-ANI", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->ani);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->aniii)) {
</del><ins>+        if (!zstr(caller_profile->aniii)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-ANI-II", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->aniii);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->destination_number)) {
</del><ins>+        if (!zstr(caller_profile->destination_number)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Destination-Number", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->destination_number);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->uuid)) {
</del><ins>+        if (!zstr(caller_profile->uuid)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Unique-ID", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->uuid);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->source)) {
</del><ins>+        if (!zstr(caller_profile->source)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Source", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->source);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->context)) {
</del><ins>+        if (!zstr(caller_profile->context)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Context", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->context);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->rdnis)) {
</del><ins>+        if (!zstr(caller_profile->rdnis)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-RDNIS", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->rdnis);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->chan_name)) {
</del><ins>+        if (!zstr(caller_profile->chan_name)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Channel-Name", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->chan_name);
</span><span class="cx">         }
</span><del>-        if (!switch_strlen_zero(caller_profile->profile_index)) {
</del><ins>+        if (!zstr(caller_profile->profile_index)) {
</ins><span class="cx">                 switch_snprintf(header_name, sizeof(header_name), "%s-Profile-Index", prefix);
</span><span class="cx">                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, header_name, caller_profile->profile_index);
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_channelc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_channel.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_channel.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_channel.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -317,7 +317,7 @@
</span><span class="cx">         int i, argc;
</span><span class="cx">         char *argv[256];
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(dtmf_string)) {
</del><ins>+        if (zstr(dtmf_string)) {
</ins><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -536,7 +536,7 @@
</span><span class="cx">         const char *val = NULL, *r = NULL;
</span><span class="cx">         switch_assert(channel != NULL);
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(varname)) {
</del><ins>+        if (!zstr(varname)) {
</ins><span class="cx">                 if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE))) {
</span><span class="cx">                         switch_core_session_t *session;
</span><span class="cx">                         if ((session = switch_core_session_locate(uuid))) {
</span><span class="lines">@@ -599,7 +599,7 @@
</span><span class="cx">         const char *old = NULL;
</span><span class="cx">
</span><span class="cx">         switch_assert(channel != NULL);
</span><del>-        if (!switch_strlen_zero(channel->name)) {
</del><ins>+        if (!zstr(channel->name)) {
</ins><span class="cx">                 old = channel->name;
</span><span class="cx">         }
</span><span class="cx">         channel->name = NULL;
</span><span class="lines">@@ -619,7 +619,7 @@
</span><span class="cx"> SWITCH_DECLARE(char *) switch_channel_get_name(switch_channel_t *channel)
</span><span class="cx"> {
</span><span class="cx">         switch_assert(channel != NULL);
</span><del>-        return (!switch_strlen_zero(channel->name)) ? channel->name : "N/A";
</del><ins>+        return (!zstr(channel->name)) ? channel->name : "N/A";
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> SWITCH_DECLARE(switch_status_t) switch_channel_set_profile_var(switch_channel_t *channel, const char *name, const char *val)
</span><span class="lines">@@ -629,7 +629,7 @@
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(channel->profile_mutex);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(val)) {
</del><ins>+        if (!zstr(val)) {
</ins><span class="cx">                 v = switch_core_strdup(channel->caller_profile->pool, val);
</span><span class="cx">         } else {
</span><span class="cx">                 v = SWITCH_BLANK_STRING;
</span><span class="lines">@@ -689,9 +689,9 @@
</span><span class="cx">         switch_assert(channel != NULL);
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(channel->profile_mutex);
</span><del>-        if (channel->variables && !switch_strlen_zero(varname)) {
</del><ins>+        if (channel->variables && !zstr(varname)) {
</ins><span class="cx">                 switch_event_del_header(channel->variables, varname);
</span><del>-                if (!switch_strlen_zero(value)) {
</del><ins>+                if (!zstr(value)) {
</ins><span class="cx">                         int ok = 1;
</span><span class="cx">                         
</span><span class="cx">                         if (var_check) {
</span><span class="lines">@@ -722,7 +722,7 @@
</span><span class="cx">         switch_assert(channel != NULL);
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(channel->profile_mutex);
</span><del>-        if (channel->variables && !switch_strlen_zero(varname)) {
</del><ins>+        if (channel->variables && !zstr(varname)) {
</ins><span class="cx">                 switch_event_del_header(channel->variables, varname);
</span><span class="cx">
</span><span class="cx">                 va_start(ap, fmt);
</span><span class="lines">@@ -750,7 +750,7 @@
</span><span class="cx">         const char *uuid;
</span><span class="cx">         switch_assert(channel != NULL);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(varname)) {
</del><ins>+        if (!zstr(varname)) {
</ins><span class="cx">                 if ((uuid = switch_channel_get_variable(channel, SWITCH_SIGNAL_BOND_VARIABLE))) {
</span><span class="cx">                         switch_core_session_t *session;
</span><span class="cx">                         if ((session = switch_core_session_locate(uuid))) {
</span><span class="lines">@@ -2126,7 +2126,7 @@
</span><span class="cx">
</span><span class="cx">         switch_channel_set_variable(channel, SWITCH_ENDPOINT_DISPOSITION_VARIABLE, "ANSWER");
</span><span class="cx">         switch_log_printf(SWITCH_CHANNEL_ID_LOG, file, func, line, switch_channel_get_uuid(channel), SWITCH_LOG_NOTICE, "Channel [%s] has been answered\n", channel->name);
</span><del>-        if ((var = switch_channel_get_variable(channel, SWITCH_CHANNEL_EXECUTE_ON_ANSWER_VARIABLE)) && !switch_strlen_zero(var)) {
</del><ins>+        if ((var = switch_channel_get_variable(channel, SWITCH_CHANNEL_EXECUTE_ON_ANSWER_VARIABLE)) && !zstr(var)) {
</ins><span class="cx">                 char *arg = NULL;
</span><span class="cx">
</span><span class="cx">                 app = switch_core_session_strdup(channel->session, var);
</span><span class="lines">@@ -2143,7 +2143,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if ((var = switch_channel_get_variable(channel, SWITCH_CHANNEL_API_ON_ANSWER_VARIABLE)) && !switch_strlen_zero(var)) {
</del><ins>+        if ((var = switch_channel_get_variable(channel, SWITCH_CHANNEL_API_ON_ANSWER_VARIABLE)) && !zstr(var)) {
</ins><span class="cx">                 switch_stream_handle_t stream = { 0 };
</span><span class="cx">                 char *arg = NULL;
</span><span class="cx">
</span><span class="lines">@@ -2214,7 +2214,7 @@
</span><span class="cx">         char *func_val = NULL;
</span><span class="cx">         int nv = 0;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(in)) {
</del><ins>+        if (zstr(in)) {
</ins><span class="cx">                 return (char *) in;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2495,7 +2495,7 @@
</span><span class="cx">         prof_names[10] = "uuid";
</span><span class="cx">
</span><span class="cx">         for (x = 0; prof[x]; x++) {
</span><del>-                if (switch_strlen_zero(prof[x])) {
</del><ins>+                if (zstr(prof[x])) {
</ins><span class="cx">                         continue;
</span><span class="cx">                 }
</span><span class="cx">                 new_len = (strlen(prof[x]) * 3) + 1;
</span><span class="lines">@@ -2558,12 +2558,12 @@
</span><span class="cx">         switch_mutex_lock(channel->profile_mutex);
</span><span class="cx">         switch_mutex_lock(other_channel->profile_mutex);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(channel->caller_profile->callee_id_name)) {
</del><ins>+        if (!zstr(channel->caller_profile->callee_id_name)) {
</ins><span class="cx">                 other_channel->caller_profile->callee_id_name = switch_core_strdup(channel->caller_profile->pool, channel->caller_profile->callee_id_name);
</span><span class="cx">                 x++;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(channel->caller_profile->callee_id_number)) {
</del><ins>+        if (!zstr(channel->caller_profile->callee_id_number)) {
</ins><span class="cx">                 other_channel->caller_profile->callee_id_number = switch_core_strdup(channel->caller_profile->pool, channel->caller_profile->callee_id_number);
</span><span class="cx">                 x++;
</span><span class="cx">         }
</span><span class="lines">@@ -2621,7 +2621,7 @@
</span><span class="cx">                 ocp = switch_channel_get_originator_caller_profile(channel);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(caller_profile->caller_id_name)) {
</del><ins>+        if (!zstr(caller_profile->caller_id_name)) {
</ins><span class="cx">                 cid_buf = switch_core_session_sprintf(channel->session, "\"%s\" <%s>", caller_profile->caller_id_name,
</span><span class="cx">                                                                                          switch_str_nil(caller_profile->caller_id_number));
</span><span class="cx">         } else {
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_consolec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_console.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_console.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_console.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -464,7 +464,7 @@
</span><span class="cx">                 line = el_gets(el, &count);
</span><span class="cx">
</span><span class="cx">                 if (count > 1) {
</span><del>-                        if (!switch_strlen_zero(line)) {
</del><ins>+                        if (!zstr(line)) {
</ins><span class="cx">                                 char *cmd = strdup(line);
</span><span class="cx">                                 char *p;
</span><span class="cx">                                 const LineInfo *lf = el_line(el);
</span><span class="lines">@@ -513,7 +513,7 @@
</span><span class="cx">
</span><span class="cx">         switch_copy_string(h->last, target, sizeof(h->last));
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(target)) {
</del><ins>+        if (!zstr(target)) {
</ins><span class="cx">                 if ((++h->hits % 4) == 0) {
</span><span class="cx">                         fprintf(h->out, "\n");
</span><span class="cx">                 }
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_corec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_core.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_core.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_core.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -957,7 +957,7 @@
</span><span class="cx">                                 const char *dft = switch_xml_attr(x_list, "default");
</span><span class="cx">                                 switch_bool_t default_type = SWITCH_TRUE;
</span><span class="cx">
</span><del>-                                if (switch_strlen_zero(name)) {
</del><ins>+                                if (zstr(name)) {
</ins><span class="cx">                                         continue;
</span><span class="cx">                                 }
</span><span class="cx">
</span><span class="lines">@@ -1393,34 +1393,34 @@
</span><span class="cx"> #endif
</span><span class="cx">                                 } else if (!strcasecmp(var, "colorize-console") && switch_true(val)) {
</span><span class="cx">                                         runtime.colorize_console = SWITCH_TRUE;
</span><del>-                                } else if (!strcasecmp(var, "mailer-app") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "mailer-app") && !zstr(val)) {
</ins><span class="cx">                                         runtime.mailer_app = switch_core_strdup(runtime.memory_pool, val);
</span><span class="cx">                                 } else if (!strcasecmp(var, "mailer-app-args") && val) {
</span><span class="cx">                                         runtime.mailer_app_args = switch_core_strdup(runtime.memory_pool, val);
</span><del>-                                } else if (!strcasecmp(var, "sessions-per-second") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "sessions-per-second") && !zstr(val)) {
</ins><span class="cx">                                         switch_core_sessions_per_second(atoi(val));
</span><del>-                                } else if (!strcasecmp(var, "max_dtmf_duration") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "max_dtmf_duration") && !zstr(val)) {
</ins><span class="cx">                                         int tmp = atoi(val);
</span><span class="cx">                                         if (tmp > 0) {
</span><span class="cx">                                                 switch_core_max_dtmf_duration((uint32_t) tmp);
</span><span class="cx">                                         }
</span><del>-                                } else if (!strcasecmp(var, "min_dtmf_duration") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "min_dtmf_duration") && !zstr(val)) {
</ins><span class="cx">                                         int tmp = atoi(val);
</span><span class="cx">                                         if (tmp > 0) {
</span><span class="cx">                                                 switch_core_min_dtmf_duration((uint32_t) tmp);
</span><span class="cx">                                         }
</span><del>-                                } else if (!strcasecmp(var, "default_dtmf_duration") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "default_dtmf_duration") && !zstr(val)) {
</ins><span class="cx">                                         int tmp = atoi(val);
</span><span class="cx">                                         if (tmp > 0) {
</span><span class="cx">                                                 switch_core_default_dtmf_duration((uint32_t) tmp);
</span><span class="cx">                                         }
</span><span class="cx">                                 } else if (!strcasecmp(var, "disable-monotonic-timing")) {
</span><span class="cx">                                         switch_time_set_monotonic(SWITCH_FALSE);
</span><del>-                                } else if (!strcasecmp(var, "max-sessions") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "max-sessions") && !zstr(val)) {
</ins><span class="cx">                                         switch_core_session_limit(atoi(val));
</span><del>-                                } else if (!strcasecmp(var, "rtp-start-port") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "rtp-start-port") && !zstr(val)) {
</ins><span class="cx">                                         switch_rtp_set_start_port((switch_port_t) atoi(val));
</span><del>-                                } else if (!strcasecmp(var, "rtp-end-port") && !switch_strlen_zero(val)) {
</del><ins>+                                } else if (!strcasecmp(var, "rtp-end-port") && !zstr(val)) {
</ins><span class="cx">                                         switch_rtp_set_end_port((switch_port_t) atoi(val));
</span><span class="cx"> #ifdef ENABLE_ZRTP
</span><span class="cx">                                 } else if (!strcasecmp(var, "rtp-enable-zrtp")) {
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_core_asrc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_core_asr.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_core_asr.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_core_asr.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -96,7 +96,7 @@
</span><span class="cx">
</span><span class="cx">         switch_assert(ah != NULL);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(grammar)) {
</del><ins>+        if (zstr(grammar)) {
</ins><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -111,7 +111,7 @@
</span><span class="cx">         while (data && *data == ' ') {
</span><span class="cx">                 data++;
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -120,7 +120,7 @@
</span><span class="cx">         if (*data == '{') {
</span><span class="cx">                 param_string = data + 1;
</span><span class="cx">                 data = switch_find_end_paren(data, '{', '}');
</span><del>-                if (switch_strlen_zero(data)) {
</del><ins>+                if (zstr(data)) {
</ins><span class="cx">                         status = SWITCH_STATUS_FALSE;
</span><span class="cx">                         goto done;
</span><span class="cx">                 } else {        
</span><span class="lines">@@ -130,7 +130,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         /* set ASR params */
</span><del>-        if (!switch_strlen_zero(param_string)) {
</del><ins>+        if (!zstr(param_string)) {
</ins><span class="cx">                 char *param[256] = { 0 };
</span><span class="cx">                 int i;
</span><span class="cx">                 int argc = switch_separate_string(param_string, ',', param, (sizeof(param) / sizeof(param[0])));
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_core_filec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_core_file.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_core_file.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_core_file.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -53,7 +53,7 @@
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(file_path)) {
</del><ins>+        if (zstr(file_path)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Invalid Filename\n");
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_core_ioc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_core_io.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_core_io.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_core_io.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -1182,7 +1182,7 @@
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(dtmf_string)) {
</del><ins>+        if (zstr(dtmf_string)) {
</ins><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_core_memoryc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_core_memory.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_core_memory.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_core_memory.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -139,7 +139,7 @@
</span><span class="cx">                 return NULL;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(todup)) {
</del><ins>+        if (zstr(todup)) {
</ins><span class="cx">                 return SWITCH_BLANK_STRING;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -235,7 +235,7 @@
</span><span class="cx">                 return NULL;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(todup)) {
</del><ins>+        if (zstr(todup)) {
</ins><span class="cx">                 return SWITCH_BLANK_STRING;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -275,7 +275,7 @@
</span><span class="cx">                 return NULL;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(todup)) {
</del><ins>+        if (zstr(todup)) {
</ins><span class="cx">                 return SWITCH_BLANK_STRING;
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_core_sessionc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_core_session.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_core_session.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_core_session.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -373,7 +373,7 @@
</span><span class="cx">                 switch_assert(channel != NULL);
</span><span class="cx">
</span><span class="cx">                 forwardvar = switch_channel_get_variable(channel, SWITCH_MAX_FORWARDS_VARIABLE);
</span><del>-                if (!switch_strlen_zero(forwardvar)) {
</del><ins>+                if (!zstr(forwardvar)) {
</ins><span class="cx">                         forwardval = atoi(forwardvar) - 1;
</span><span class="cx">                 }
</span><span class="cx">                 if (forwardval <= 0) {
</span><span class="lines">@@ -1494,7 +1494,7 @@
</span><span class="cx">                 char *myarg = NULL;
</span><span class="cx">                 if (expanded) {
</span><span class="cx">                         myarg = switch_mprintf("%s(%s)", app, expanded);
</span><del>-                } else if (!switch_strlen_zero(arg)) {
</del><ins>+                } else if (!zstr(arg)) {
</ins><span class="cx">                         myarg = switch_mprintf("%s(%s)", app, arg);
</span><span class="cx">                 } else {
</span><span class="cx">                         myarg = switch_mprintf("%s", app);
</span><span class="lines">@@ -1583,11 +1583,11 @@
</span><span class="cx">         new_profile = switch_caller_profile_clone(session, profile);
</span><span class="cx">         new_profile->destination_number = switch_core_strdup(new_profile->pool, exten);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(dialplan)) {
</del><ins>+        if (!zstr(dialplan)) {
</ins><span class="cx">                 new_profile->dialplan = switch_core_strdup(new_profile->pool, dialplan);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(context)) {
</del><ins>+        if (!zstr(context)) {
</ins><span class="cx">                 new_profile->context = switch_core_strdup(new_profile->pool, context);
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_core_speechc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_core_speech.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_core_speech.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_core_speech.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -45,7 +45,7 @@
</span><span class="cx">         char buf[256] = "";
</span><span class="cx">         char *param = NULL;
</span><span class="cx">
</span><del>-        if (!sh || !flags || switch_strlen_zero(module_name)) {
</del><ins>+        if (!sh || !flags || zstr(module_name)) {
</ins><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -102,7 +102,7 @@
</span><span class="cx">
</span><span class="cx">         switch_assert(sh != NULL);
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(text)) {
</del><ins>+        if (zstr(text)) {
</ins><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -117,7 +117,7 @@
</span><span class="cx">         while (data && *data == ' ') {
</span><span class="cx">                 data++;
</span><span class="cx">         }
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 status = SWITCH_STATUS_FALSE;
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -126,7 +126,7 @@
</span><span class="cx">         if (*data == '{') {
</span><span class="cx">                 param_string = data + 1;
</span><span class="cx">                 data = switch_find_end_paren(data, '{', '}');
</span><del>-                if (switch_strlen_zero(data)) {
</del><ins>+                if (zstr(data)) {
</ins><span class="cx">                         status = SWITCH_STATUS_FALSE;
</span><span class="cx">                         goto done;
</span><span class="cx">                 } else {
</span><span class="lines">@@ -136,7 +136,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">         /* set TTS params */
</span><del>-        if (!switch_strlen_zero(param_string)) {
</del><ins>+        if (!zstr(param_string)) {
</ins><span class="cx">                 char *param[256] = { 0 };
</span><span class="cx">                 int i;
</span><span class="cx">                 int argc = switch_separate_string(param_string, ',', param, (sizeof(param) / sizeof(param[0])));
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_core_sqldbc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_core_sqldb.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_core_sqldb.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_core_sqldb.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -316,7 +316,7 @@
</span><span class="cx">                         char *state = switch_event_get_header_nil(event, "channel-state-number");
</span><span class="cx">                         switch_channel_state_t state_i = CS_DESTROY;
</span><span class="cx">
</span><del>-                        if (!switch_strlen_zero(state)) {
</del><ins>+                        if (!zstr(state)) {
</ins><span class="cx">                                 state_i = atoi(state);
</span><span class="cx">                         }
</span><span class="cx">
</span><span class="lines">@@ -375,7 +375,7 @@
</span><span class="cx">                         const char *syntax = switch_event_get_header_nil(event, "syntax");
</span><span class="cx">                         const char *key = switch_event_get_header_nil(event, "key");
</span><span class="cx">                         const char *filename = switch_event_get_header_nil(event, "filename");
</span><del>-                        if (!switch_strlen_zero(type) && !switch_strlen_zero(name)) {
</del><ins>+                        if (!zstr(type) && !zstr(name)) {
</ins><span class="cx">                                 sql =
</span><span class="cx">                                         switch_mprintf("insert into interfaces (type,name,description,syntax,key,filename) values('%q','%q','%q','%q','%q','%q')",
</span><span class="cx">                                                                  type, name, switch_str_nil(description), switch_str_nil(syntax), switch_str_nil(key), switch_str_nil(filename)
</span><span class="lines">@@ -387,7 +387,7 @@
</span><span class="cx">                 {
</span><span class="cx">                         const char *type = switch_event_get_header_nil(event, "type");
</span><span class="cx">                         const char *name = switch_event_get_header_nil(event, "name");
</span><del>-                        if (!switch_strlen_zero(type) && !switch_strlen_zero(name)) {
</del><ins>+                        if (!zstr(type) && !zstr(name)) {
</ins><span class="cx">                                 sql = switch_mprintf("delete from interfaces where type='%q' and name='%q'", type, name);
</span><span class="cx">                         }
</span><span class="cx">                         break;
</span><span class="lines">@@ -396,7 +396,7 @@
</span><span class="cx">                 {
</span><span class="cx">                         const char *type = switch_event_get_header_nil(event, "secure_type");
</span><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Secure Type: %s\n", type);
</span><del>-                        if (switch_strlen_zero(type)) {
</del><ins>+                        if (zstr(type)) {
</ins><span class="cx">                                 break;
</span><span class="cx">                         }
</span><span class="cx">                         sql = switch_mprintf("update channels set secure='%s' where uuid='%s'",
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_core_state_machinec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_core_state_machine.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_core_state_machine.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_core_state_machine.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -85,7 +85,7 @@
</span><span class="cx">                 char *dp[25];
</span><span class="cx">                 int argc, x, count = 0;
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(caller_profile->dialplan)) {
</del><ins>+                if (!zstr(caller_profile->dialplan)) {
</ins><span class="cx">                         if ((dpstr = switch_core_session_strdup(session, caller_profile->dialplan))) {
</span><span class="cx">                                 expanded = switch_channel_expand_variables(session->channel, dpstr);
</span><span class="cx">                                 argc = switch_separate_string(expanded, ',', dp, (sizeof(dp) / sizeof(dp[0])));
</span><span class="lines">@@ -482,7 +482,7 @@
</span><span class="cx">                 use_session = session;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(hook_var)) {
</del><ins>+        if (!zstr(hook_var)) {
</ins><span class="cx">                 switch_stream_handle_t stream = { 0 };
</span><span class="cx">                 char *cmd = switch_core_session_strdup(session, hook_var);
</span><span class="cx">                 char *arg = NULL;
</span><span class="lines">@@ -552,7 +552,7 @@
</span><span class="cx">         driver_state_handler = endpoint_interface->state_handler;
</span><span class="cx">         switch_assert(driver_state_handler != NULL);
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(var)) {
</del><ins>+        if (!zstr(var)) {
</ins><span class="cx">                 if (!strcasecmp(var, "a_only")) {
</span><span class="cx">                         if (switch_channel_get_originator_caller_profile(session->channel)) {
</span><span class="cx">                                 do_extra_handlers = 0;
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_cppcpp"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_cpp.cpp (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_cpp.cpp        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_cpp.cpp        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -55,7 +55,7 @@
</span><span class="cx">         switch_name_event(event_name, &e_event_id);
</span><span class="cx">         switch_core_new_memory_pool(&pool);
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(subclass_name)) {
</del><ins>+        if (!zstr(subclass_name)) {
</ins><span class="cx">                 e_subclass_name = switch_core_strdup(pool, subclass_name);
</span><span class="cx">         } else {
</span><span class="cx">                 e_subclass_name = NULL;
</span><span class="lines">@@ -124,7 +124,7 @@
</span><span class="cx">         menu = NULL;
</span><span class="cx">         switch_core_new_memory_pool(&pool);
</span><span class="cx">         switch_assert(pool);
</span><del>-        if (switch_strlen_zero(name)) {
</del><ins>+        if (zstr(name)) {
</ins><span class="cx">                 name = "no name";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -227,7 +227,7 @@
</span><span class="cx">                 event_id = SWITCH_EVENT_MESSAGE;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(subclass_name) && event_id != SWITCH_EVENT_CUSTOM) {
</del><ins>+        if (!zstr(subclass_name) && event_id != SWITCH_EVENT_CUSTOM) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG,SWITCH_LOG_WARNING, "Changing event type to custom because you specified a subclass name!\n");
</span><span class="cx">                 event_id = SWITCH_EVENT_CUSTOM;
</span><span class="cx">         }
</span><span class="lines">@@ -1204,7 +1204,7 @@
</span><span class="cx">         this_check(SWITCH_STATUS_FALSE);
</span><span class="cx">         sanity_check(SWITCH_STATUS_FALSE);
</span><span class="cx">         
</span><del>- if (switch_strlen_zero(result)) {
</del><ins>+ if (zstr(result)) {
</ins><span class="cx">                 return SWITCH_STATUS_SUCCESS;        
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_eventc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_event.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_event.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_event.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -1071,7 +1071,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(data)) {
</del><ins>+        if (!zstr(data)) {
</ins><span class="cx">                 body = data;
</span><span class="cx">         } else if (event->body) {
</span><span class="cx">                 body = event->body;
</span><span class="lines">@@ -1606,7 +1606,7 @@
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">         for (x = 0; prof[x]; x++) {
</span><del>-                if (switch_strlen_zero(prof[x])) {
</del><ins>+                if (zstr(prof[x])) {
</ins><span class="cx">                         continue;
</span><span class="cx">                 }
</span><span class="cx">                 new_len = (strlen(prof[x]) * 3) + 1;
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_ivrc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_ivr.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_ivr.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_ivr.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -463,7 +463,7 @@
</span><span class="cx">         char *event_lock = switch_event_get_header(event, "event-lock");
</span><span class="cx">         switch_status_t status = SWITCH_STATUS_FALSE;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(cmd)) {
</del><ins>+        if (zstr(cmd)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Invalid Command!\n");
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="lines">@@ -569,19 +569,19 @@
</span><span class="cx">                 char *transport = switch_event_get_header(event, "transport");
</span><span class="cx">                 char *flags = switch_event_get_header(event, "flags");
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(local_ip)) {
</del><ins>+                if (zstr(local_ip)) {
</ins><span class="cx">                         local_ip = "127.0.0.1";
</span><span class="cx">                 }
</span><del>-                if (switch_strlen_zero(remote_ip)) {
</del><ins>+                if (zstr(remote_ip)) {
</ins><span class="cx">                         remote_ip = "127.0.0.1";
</span><span class="cx">                 }
</span><del>-                if (switch_strlen_zero(local_port)) {
</del><ins>+                if (zstr(local_port)) {
</ins><span class="cx">                         local_port = "8025";
</span><span class="cx">                 }
</span><del>-                if (switch_strlen_zero(remote_port)) {
</del><ins>+                if (zstr(remote_port)) {
</ins><span class="cx">                         remote_port = "8026";
</span><span class="cx">                 }
</span><del>-                if (switch_strlen_zero(transport)) {
</del><ins>+                if (zstr(transport)) {
</ins><span class="cx">                         transport = "udp";
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -972,7 +972,7 @@
</span><span class="cx">                 *terminator = '\0';
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(terminators)) {
</del><ins>+        if (!zstr(terminators)) {
</ins><span class="cx">                 for (i = 0; i < x; i++) {
</span><span class="cx">                         if (strchr(terminators, buf[i]) && terminator != NULL) {
</span><span class="cx">                                 *terminator = buf[i];
</span><span class="lines">@@ -1038,7 +1038,7 @@
</span><span class="cx">                                         break;
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(terminators) && strchr(terminators, dtmf.digit) && terminator != NULL) {
</del><ins>+                                if (!zstr(terminators) && strchr(terminators, dtmf.digit) && terminator != NULL) {
</ins><span class="cx">                                         *terminator = dtmf.digit;
</span><span class="cx">                                         return SWITCH_STATUS_SUCCESS;
</span><span class="cx">                                 }
</span><span class="lines">@@ -1281,7 +1281,7 @@
</span><span class="cx">         const char *forwardvar = switch_channel_get_variable(channel, SWITCH_MAX_FORWARDS_VARIABLE);
</span><span class="cx">         int forwardval = 70;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(forwardvar)) {
</del><ins>+        if (!zstr(forwardvar)) {
</ins><span class="cx">                 forwardval = atoi(forwardvar) - 1;
</span><span class="cx">         }
</span><span class="cx">         if (forwardval <= 0) {
</span><span class="lines">@@ -1301,26 +1301,26 @@
</span><span class="cx">         if ((profile = switch_channel_get_caller_profile(channel))) {
</span><span class="cx">                 const char *var;
</span><span class="cx">                 
</span><del>-                if (switch_strlen_zero(dialplan)) {
</del><ins>+                if (zstr(dialplan)) {
</ins><span class="cx">                         dialplan = profile->dialplan;
</span><del>-                        if (!switch_strlen_zero(dialplan) && !strcasecmp(dialplan, "inline")) {
</del><ins>+                        if (!zstr(dialplan) && !strcasecmp(dialplan, "inline")) {
</ins><span class="cx">                                 dialplan = NULL;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(context)) {
</del><ins>+                if (zstr(context)) {
</ins><span class="cx">                         context = profile->context;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(dialplan)) {
</del><ins>+                if (zstr(dialplan)) {
</ins><span class="cx">                         dialplan = "XML";
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(context)) {
</del><ins>+                if (zstr(context)) {
</ins><span class="cx">                         context = "default";
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(extension)) {
</del><ins>+                if (zstr(extension)) {
</ins><span class="cx">                         extension = "service";
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -1750,7 +1750,7 @@
</span><span class="cx">                 return off;
</span><span class="cx">
</span><span class="cx">         for (; hi; hi = hi->next) {
</span><del>-                if (!switch_strlen_zero(hi->name) && !switch_strlen_zero(hi->value) && ((variable = switch_xml_add_child_d(xml, hi->name, off++)))) {
</del><ins>+                if (!zstr(hi->name) && !zstr(hi->value) && ((variable = switch_xml_add_child_d(xml, hi->name, off++)))) {
</ins><span class="cx">                         char *data;
</span><span class="cx">                         switch_size_t dlen = strlen(hi->value) * 3;
</span><span class="cx">
</span><span class="lines">@@ -1815,11 +1815,11 @@
</span><span class="cx">                         goto error;
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(caller_profile->dialplan)) {
</del><ins>+                if (!zstr(caller_profile->dialplan)) {
</ins><span class="cx">                         switch_xml_set_attr_d(x_callflow, "dialplan", caller_profile->dialplan);
</span><span class="cx">                 }
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(caller_profile->profile_index)) {
</del><ins>+                if (!zstr(caller_profile->profile_index)) {
</ins><span class="cx">                         switch_xml_set_attr_d(x_callflow, "profile_index", caller_profile->profile_index);
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -2185,7 +2185,7 @@
</span><span class="cx">         char * prefix_buffer = NULL, *prefix;
</span><span class="cx">         size_t buffer_size =0;
</span><span class="cx">         size_t prefix_size=0;
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 goto error;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -2208,7 +2208,7 @@
</span><span class="cx">
</span><span class="cx">         status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(prefix)) {
</del><ins>+        if (!zstr(prefix)) {
</ins><span class="cx">                 prefix_size = strlen(prefix);
</span><span class="cx">                 buffer_size = 1024 + prefix_size + 1;
</span><span class="cx">                 prefix_buffer = switch_core_session_alloc(session, buffer_size);
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_ivr_asyncc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_ivr_async.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_ivr_async.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_ivr_async.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -653,7 +653,7 @@
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(require_group)) {
</del><ins>+                if (!zstr(require_group)) {
</ins><span class="cx">                         int argc, i;
</span><span class="cx">                         int ok = 0;
</span><span class="cx">                         char *argv[10] = { 0 };
</span><span class="lines">@@ -1774,7 +1774,7 @@
</span><span class="cx"> switch_core_session_get_read_impl(session, &read_impl);
</span><span class="cx">
</span><span class="cx">         
</span><del>-        if (switch_strlen_zero(key)) {
</del><ins>+        if (zstr(key)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No Key Specified!\n");
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="lines">@@ -1786,7 +1786,7 @@
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="cx">                 for (i = 0; i < cont->index; i++) {
</span><del>-                        if (!switch_strlen_zero(cont->list[i].key) && !strcasecmp(key, cont->list[i].key)) {
</del><ins>+                        if (!zstr(cont->list[i].key) && !strcasecmp(key, cont->list[i].key)) {
</ins><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Re-enabling %s\n", key);
</span><span class="cx">                                 cont->list[i].up = 1;
</span><span class="cx">                                 cont->list[i].hits = 0;
</span><span class="lines">@@ -1797,7 +1797,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(tone_spec)) {
</del><ins>+        if (zstr(tone_spec)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "No Spec Specified!\n");
</span><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="lines">@@ -1876,7 +1876,7 @@
</span><span class="cx">         }
</span><span class="cx">
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(flags)) {
</del><ins>+        if (zstr(flags)) {
</ins><span class="cx">                 bflags = SMBF_READ_REPLACE;
</span><span class="cx">         } else {
</span><span class="cx">                 if (strchr(flags, 'o')) {
</span><span class="lines">@@ -2117,7 +2117,7 @@
</span><span class="cx">                 switch_core_event_hook_add_recv_dtmf(session, meta_on_dtmf);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(app)) {
</del><ins>+        if (!zstr(app)) {
</ins><span class="cx">                 if ((bind_flags & SBF_DIAL_ALEG)) {
</span><span class="cx">                         md->sr[SWITCH_DTMF_RECV].up = 1;
</span><span class="cx">                         md->sr[SWITCH_DTMF_RECV].map[key].app = switch_core_session_strdup(session, app);
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_ivr_bridgec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_ivr_bridge.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_ivr_bridge.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_ivr_bridge.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -93,20 +93,20 @@
</span><span class="cx">                 name = caller_profile->callee_id_name;
</span><span class="cx">                 number = caller_profile->callee_id_number;
</span><span class="cx">                 
</span><del>-                if (switch_strlen_zero(name)) {
</del><ins>+                if (zstr(name)) {
</ins><span class="cx">                         name = caller_profile->destination_number;
</span><span class="cx">                 }
</span><del>-                if (switch_strlen_zero(number)) {
</del><ins>+                if (zstr(number)) {
</ins><span class="cx">                         number = caller_profile->destination_number;
</span><span class="cx">                 }
</span><span class="cx">         } else {
</span><span class="cx">                 name = caller_profile->caller_id_name;
</span><span class="cx">                 number = caller_profile->caller_id_number;
</span><span class="cx">                 
</span><del>-                if (switch_strlen_zero(name)) {
</del><ins>+                if (zstr(name)) {
</ins><span class="cx">                         name = caller_profile->destination_number;
</span><span class="cx">                 }
</span><del>-                if (switch_strlen_zero(number)) {
</del><ins>+                if (zstr(number)) {
</ins><span class="cx">                         number = caller_profile->destination_number;
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="lines">@@ -482,7 +482,7 @@
</span><span class="cx">                 hook_var = switch_channel_get_variable(chan_a, SWITCH_API_BRIDGE_END_VARIABLE);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(hook_var)) {
</del><ins>+        if (!zstr(hook_var)) {
</ins><span class="cx">                 switch_stream_handle_t stream = { 0 };
</span><span class="cx">                 char *cmd = switch_core_session_strdup(session_a, hook_var);
</span><span class="cx">                 char *arg = NULL;
</span><span class="lines">@@ -546,7 +546,7 @@
</span><span class="cx">
</span><span class="cx">         switch_channel_set_variable(switch_core_session_get_channel(session), SWITCH_TRANSFER_AFTER_BRIDGE_VARIABLE, NULL);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(where) && (mydata = switch_core_session_strdup(session, where))) {
</del><ins>+        if (!zstr(where) && (mydata = switch_core_session_strdup(session, where))) {
</ins><span class="cx">                 if ((argc = switch_separate_string(mydata, ':', argv, (sizeof(argv) / sizeof(argv[0])))) >= 1) {
</span><span class="cx">                         switch_ivr_session_transfer(session, argv[0], argv[1], argv[2]);
</span><span class="cx">                 } else {
</span><span class="lines">@@ -787,7 +787,7 @@
</span><span class="cx"> const char *sbv = switch_channel_get_variable(other_channel, SWITCH_SIGNAL_BRIDGE_VARIABLE);
</span><span class="cx">                 const char *var;
</span><span class="cx">
</span><del>- if (!switch_strlen_zero(sbv) && !strcmp(sbv, switch_core_session_get_uuid(session))) {
</del><ins>+ if (!zstr(sbv) && !strcmp(sbv, switch_core_session_get_uuid(session))) {
</ins><span class="cx">
</span><span class="cx"> switch_channel_set_variable(other_channel, SWITCH_SIGNAL_BRIDGE_VARIABLE, NULL);
</span><span class="cx"> switch_channel_set_variable(other_channel, SWITCH_BRIDGE_VARIABLE, NULL);
</span><span class="lines">@@ -1147,7 +1147,7 @@
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Restore media to %s\n", switch_channel_get_name(channel));
</span><span class="cx">                 switch_ivr_media(switch_core_session_get_uuid(session), SMF_IMMEDIATE);
</span><span class="cx">
</span><del>-                if (!switch_strlen_zero(sbv) && (sbsession = switch_core_session_locate(sbv))) {
</del><ins>+                if (!zstr(sbv) && (sbsession = switch_core_session_locate(sbv))) {
</ins><span class="cx">                         switch_channel_t *sbchannel = switch_core_session_get_channel(sbsession);
</span><span class="cx">                         switch_channel_hangup(sbchannel, SWITCH_CAUSE_ATTENDED_TRANSFER);
</span><span class="cx">                         switch_core_session_rwunlock(sbsession);
</span><span class="lines">@@ -1321,7 +1321,7 @@
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(uuid) || !(rsession = switch_core_session_locate(uuid))) {
</del><ins>+        if (zstr(uuid) || !(rsession = switch_core_session_locate(uuid))) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "no uuid %s\n", uuid);
</span><span class="cx">                 return;
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_ivr_menuc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_ivr_menu.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_ivr_menu.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_ivr_menu.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -140,35 +140,35 @@
</span><span class="cx">                 inter_timeout = timeout / 2;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(name)) {
</del><ins>+        if (!zstr(name)) {
</ins><span class="cx">                 menu->name = switch_core_strdup(menu->pool, name);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(greeting_sound)) {
</del><ins>+        if (!zstr(greeting_sound)) {
</ins><span class="cx">                 menu->greeting_sound = switch_core_strdup(menu->pool, greeting_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(short_greeting_sound)) {
</del><ins>+        if (!zstr(short_greeting_sound)) {
</ins><span class="cx">                 menu->short_greeting_sound = switch_core_strdup(menu->pool, short_greeting_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(invalid_sound)) {
</del><ins>+        if (!zstr(invalid_sound)) {
</ins><span class="cx">                 menu->invalid_sound = switch_core_strdup(menu->pool, invalid_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(exit_sound)) {
</del><ins>+        if (!zstr(exit_sound)) {
</ins><span class="cx">                 menu->exit_sound = switch_core_strdup(menu->pool, exit_sound);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(confirm_macro)) {
</del><ins>+        if (!zstr(confirm_macro)) {
</ins><span class="cx">                 menu->confirm_macro = switch_core_strdup(menu->pool, confirm_macro);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(tts_engine)) {
</del><ins>+        if (!zstr(tts_engine)) {
</ins><span class="cx">                 menu->tts_engine = switch_core_strdup(menu->pool, tts_engine);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(tts_voice)) {
</del><ins>+        if (!zstr(tts_voice)) {
</ins><span class="cx">                 menu->tts_voice = switch_core_strdup(menu->pool, tts_voice);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -294,7 +294,7 @@
</span><span class="cx">         char *sound_expanded = sound;
</span><span class="cx">         switch_size_t menu_buf_len = 0;
</span><span class="cx">
</span><del>-        if (!session || !menu || switch_strlen_zero(sound)) {
</del><ins>+        if (!session || !menu || zstr(sound)) {
</ins><span class="cx">                 return status;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -396,7 +396,7 @@
</span><span class="cx">                 switch_goto_status(SWITCH_STATUS_FALSE, end);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!session || !stack || switch_strlen_zero(name)) {
</del><ins>+        if (!session || !stack || zstr(name)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Invalid menu context\n");
</span><span class="cx">                 switch_goto_status(SWITCH_STATUS_FALSE, end);
</span><span class="cx">         }
</span><span class="lines">@@ -408,7 +408,7 @@
</span><span class="cx">                 switch_goto_status(SWITCH_STATUS_FALSE, end);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(menu->tts_engine) && !switch_strlen_zero(menu->tts_voice)) {
</del><ins>+        if (!zstr(menu->tts_engine) && !zstr(menu->tts_voice)) {
</ins><span class="cx">                 switch_channel_set_variable(channel, "tts_engine", menu->tts_engine);
</span><span class="cx">                 switch_channel_set_variable(channel, "tts_voice", menu->tts_voice);
</span><span class="cx">         }
</span><span class="lines">@@ -456,7 +456,7 @@
</span><span class="cx">                                 char substituted[1024];
</span><span class="cx">                                 char *use_arg = ap->arg;
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(menu->tts_engine) && !switch_strlen_zero(menu->tts_voice)) {
</del><ins>+                                if (!zstr(menu->tts_engine) && !zstr(menu->tts_voice)) {
</ins><span class="cx">                                         switch_channel_set_variable(channel, "tts_engine", menu->tts_engine);
</span><span class="cx">                                         switch_channel_set_variable(channel, "tts_voice", menu->tts_voice);
</span><span class="cx">                                 }
</span><span class="lines">@@ -516,7 +516,7 @@
</span><span class="cx">
</span><span class="cx">                                                         status = SWITCH_STATUS_FALSE;
</span><span class="cx">
</span><del>-                                                        if (!switch_strlen_zero(aptr)) {
</del><ins>+                                                        if (!zstr(aptr)) {
</ins><span class="cx">                                                                 app_name = switch_core_session_strdup(session, aptr);
</span><span class="cx">                                                                 if ((app_arg = strchr(app_name, ' '))) {
</span><span class="cx">                                                                         *app_arg++ = '\0';
</span><span class="lines">@@ -579,7 +579,7 @@
</span><span class="cx">
</span><span class="cx">         if (stack->stack_count == 1) {
</span><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "exit-sound '%s'\n", menu->exit_sound);
</span><del>-                if (!switch_strlen_zero(menu->exit_sound)) {
</del><ins>+                if (!zstr(menu->exit_sound)) {
</ins><span class="cx">                         status = play_and_collect(session, menu, menu->exit_sound, 0);
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="lines">@@ -669,7 +669,7 @@
</span><span class="cx"> {
</span><span class="cx">         int i;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(action_name)) {
</del><ins>+        if (!zstr(action_name)) {
</ins><span class="cx">                 for(i = 0;;i++) {
</span><span class="cx">                         if (!iam[i].name) {
</span><span class="cx">                                 break;
</span><span class="lines">@@ -689,7 +689,7 @@
</span><span class="cx"> {
</span><span class="cx">         int i;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(action)) {
</del><ins>+        if (!zstr(action)) {
</ins><span class="cx">                 for(i = 0;;i++) {
</span><span class="cx">                         if (!iam[i].name) {
</span><span class="cx">                                 break;
</span><span class="lines">@@ -770,7 +770,7 @@
</span><span class="cx">
</span><span class="cx">                 switch_ivr_menu_t *menu = NULL;
</span><span class="cx">
</span><del>-                if (switch_strlen_zero(max_timeouts)) {
</del><ins>+                if (zstr(max_timeouts)) {
</ins><span class="cx">                         max_timeouts = max_failures;
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="lines">@@ -812,7 +812,7 @@
</span><span class="cx">                                 const char *digits = switch_xml_attr(xml_kvp, "digits");
</span><span class="cx">                                 const char *param = switch_xml_attr_soft(xml_kvp, "param");
</span><span class="cx">
</span><del>-                                if (is_valid_action(action) && !switch_strlen_zero(digits)) {
</del><ins>+                                if (is_valid_action(action) && !zstr(digits)) {
</ins><span class="cx">                                         switch_ivr_menu_xml_map_t *xml_map = xml_menu_ctx->map;
</span><span class="cx">                                         int found = 0;
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_ivr_originatec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_ivr_originate.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_ivr_originate.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_ivr_originate.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -409,7 +409,7 @@
</span><span class="cx">                                 
</span><span class="cx">                                 if (oglobals->monitor_early_media_fail) {
</span><span class="cx">                                         const char *var = switch_channel_get_variable(originate_status[i].peer_channel, "monitor_early_media_fail");
</span><del>-                                        if (!switch_strlen_zero(var)) {
</del><ins>+                                        if (!zstr(var)) {
</ins><span class="cx">                                                 char *fail_array[128] = {0};
</span><span class="cx">                                                 int fail_count = 0;
</span><span class="cx">                                                 char *fail_data = strdup(var);
</span><span class="lines">@@ -476,7 +476,7 @@
</span><span class="cx">                                 if (oglobals->monitor_early_media_ring) {
</span><span class="cx">                                         const char *var = switch_channel_get_variable(originate_status[i].peer_channel, "monitor_early_media_ring");
</span><span class="cx">                                         const char *var_total = switch_channel_get_variable(originate_status[i].peer_channel, "monitor_early_media_ring_total");
</span><del>-                                        if (!switch_strlen_zero(var)) {
</del><ins>+                                        if (!zstr(var)) {
</ins><span class="cx">                                                 char *ring_array[128] = {0};
</span><span class="cx">                                                 int ring_count = 0;
</span><span class="cx">                                                 char *ring_data = strdup(var);
</span><span class="lines">@@ -569,7 +569,7 @@
</span><span class="cx">                                  && !switch_channel_test_flag(originate_status[i].peer_channel, CF_TAGGED)
</span><span class="cx">                                  ) {
</span><span class="cx">                         
</span><del>-                        if (!switch_strlen_zero(oglobals->key)) {
</del><ins>+                        if (!zstr(oglobals->key)) {
</ins><span class="cx">                                 struct key_collect *collect;
</span><span class="cx">
</span><span class="cx">                                 if (oglobals->cancel_timeout < 0) {
</span><span class="lines">@@ -578,10 +578,10 @@
</span><span class="cx">
</span><span class="cx">                                 if ((collect = switch_core_session_alloc(originate_status[i].peer_session, sizeof(*collect)))) {
</span><span class="cx">                                         switch_channel_set_flag(originate_status[i].peer_channel, CF_TAGGED);
</span><del>-                                        if (!switch_strlen_zero(oglobals->key)) {
</del><ins>+                                        if (!zstr(oglobals->key)) {
</ins><span class="cx">                                                 collect->key = switch_core_session_strdup(originate_status[i].peer_session, oglobals->key);
</span><span class="cx">                                         }
</span><del>-                                        if (!switch_strlen_zero(oglobals->file)) {
</del><ins>+                                        if (!zstr(oglobals->file)) {
</ins><span class="cx">                                                 collect->file = switch_core_session_strdup(originate_status[i].peer_session, oglobals->file);
</span><span class="cx">                                         }
</span><span class="cx">                                         switch_channel_audio_sync(originate_status[i].peer_channel);
</span><span class="lines">@@ -719,7 +719,7 @@
</span><span class="cx">
</span><span class="cx">                 if (switch_channel_test_flag(caller_channel, CF_PROXY_MODE) || switch_channel_test_flag(caller_channel, CF_PROXY_MEDIA)) {
</span><span class="cx">                         ringback_data = NULL;
</span><del>-                } else if (switch_strlen_zero(ringback_data)) {
</del><ins>+                } else if (zstr(ringback_data)) {
</ins><span class="cx">                         if ((var = switch_channel_get_variable(caller_channel, SWITCH_SEND_SILENCE_WHEN_IDLE_VARIABLE))) {
</span><span class="cx">                                 int sval = atoi(var);
</span><span class="cx">
</span><span class="lines">@@ -1146,7 +1146,7 @@
</span><span class="cx">                 data++;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(data)) {
</del><ins>+        if (zstr(data)) {
</ins><span class="cx">                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_WARNING, "No origination URL specified!\n");
</span><span class="cx">                 status = SWITCH_STATUS_GENERR;
</span><span class="cx">                 goto done;
</span><span class="lines">@@ -1266,7 +1266,7 @@
</span><span class="cx">
</span><span class="cx">                 if (switch_channel_test_flag(caller_channel, CF_PROXY_MODE) || switch_channel_test_flag(caller_channel, CF_PROXY_MEDIA)) {
</span><span class="cx">                         ringback_data = NULL;
</span><del>-                } else if (switch_strlen_zero(ringback_data)) {
</del><ins>+                } else if (zstr(ringback_data)) {
</ins><span class="cx">                         const char *vvar;
</span><span class="cx">                         
</span><span class="cx">                         if ((vvar = switch_channel_get_variable(caller_channel, SWITCH_SEND_SILENCE_WHEN_IDLE_VARIABLE))) {
</span><span class="lines">@@ -2209,19 +2209,19 @@
</span><span class="cx">                                         switch_core_session_t *holding_session;
</span><span class="cx">                                         
</span><span class="cx">                                         if (caller_channel) {
</span><del>-                                                if (switch_strlen_zero(context)) {
</del><ins>+                                                if (zstr(context)) {
</ins><span class="cx">                                                         context = switch_channel_get_variable(caller_channel, "context");
</span><span class="cx">                                                 }
</span><del>-                                                if (switch_strlen_zero(dialplan)) {
</del><ins>+                                                if (zstr(dialplan)) {
</ins><span class="cx">                                                         dialplan = switch_channel_get_variable(caller_channel, "dialplan");
</span><span class="cx">                                                 }
</span><span class="cx">                                         }
</span><span class="cx">                                         
</span><del>-                                        if (switch_strlen_zero(context)) {
</del><ins>+                                        if (zstr(context)) {
</ins><span class="cx">                                                 context = "default";
</span><span class="cx">                                         }
</span><span class="cx">
</span><del>-                                        if (switch_strlen_zero(context)) {
</del><ins>+                                        if (zstr(context)) {
</ins><span class="cx">                                                 dialplan = "XML";
</span><span class="cx">                                         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_ivr_play_sayc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_ivr_play_say.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_ivr_play_say.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_ivr_play_say.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -327,7 +327,7 @@
</span><span class="cx">                                                 if (!my_tts_voice) {
</span><span class="cx">                                                         my_tts_voice = tts_voice;
</span><span class="cx">                                                 }
</span><del>-                                                if (switch_strlen_zero(tts_engine) || switch_strlen_zero(tts_voice)) {
</del><ins>+                                                if (zstr(tts_engine) || zstr(tts_voice)) {
</ins><span class="cx">                                                         switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "TTS is not configured\n");
</span><span class="cx">                                                 } else {
</span><span class="cx">                                                         status = switch_ivr_speak_text(session, my_tts_engine, my_tts_voice, odata, args);
</span><span class="lines">@@ -924,7 +924,7 @@
</span><span class="cx">         prefix = switch_channel_get_variable(channel, "sound_prefix");
</span><span class="cx">         timer_name = switch_channel_get_variable(channel, "timer_name");
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(file) || !switch_channel_media_ready(channel)) {
</del><ins>+        if (zstr(file) || !switch_channel_media_ready(channel)) {
</ins><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -982,21 +982,21 @@
</span><span class="cx">                                 dup = switch_core_session_strdup(session, alt);
</span><span class="cx">                                 engine = dup;
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(engine)) {
</del><ins>+                                if (!zstr(engine)) {
</ins><span class="cx">                                         if ((voice = strchr(engine, ':'))) {
</span><span class="cx">                                                 *voice++ = '\0';
</span><del>-                                                if (!switch_strlen_zero(voice) && (text = strchr(voice, ':'))) {
</del><ins>+                                                if (!zstr(voice) && (text = strchr(voice, ':'))) {
</ins><span class="cx">                                                         *text++ = '\0';
</span><span class="cx">                                                 }
</span><span class="cx">                                         }
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (!switch_strlen_zero(engine) && !switch_strlen_zero(voice) && !switch_strlen_zero(text)) {
</del><ins>+                                if (!zstr(engine) && !zstr(voice) && !zstr(text)) {
</ins><span class="cx">                                         if ((status = switch_ivr_speak_text(session, engine, voice, text, args)) != SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                                                 return status;
</span><span class="cx">                                         }
</span><span class="cx">                                         continue;
</span><del>-                                } else if (!switch_strlen_zero(engine) && !(voice && text)) {
</del><ins>+                                } else if (!zstr(engine) && !(voice && text)) {
</ins><span class="cx">                                         text = engine;
</span><span class="cx">                                         engine = (char *) switch_channel_get_variable(channel, "tts_engine");
</span><span class="cx">                                         voice = (char *) switch_channel_get_variable(channel, "tts_voice");
</span><span class="lines">@@ -1639,7 +1639,7 @@
</span><span class="cx">         args.buf = digit_buffer;
</span><span class="cx">         args.buflen = (uint32_t) digit_buffer_length;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(prompt_audio_file) && strcasecmp(prompt_audio_file, "silence")) {
</del><ins>+        if (!zstr(prompt_audio_file) && strcasecmp(prompt_audio_file, "silence")) {
</ins><span class="cx">                 if ((status = switch_ivr_play_file(session, NULL, prompt_audio_file, &args)) == SWITCH_STATUS_BREAK) {
</span><span class="cx">                         status = SWITCH_STATUS_SUCCESS;
</span><span class="cx">                 }
</span><span class="lines">@@ -1686,7 +1686,7 @@
</span><span class="cx">                 *digit_buffer = '\0';
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (var_name && !switch_strlen_zero(digit_buffer)) {
</del><ins>+        if (var_name && !zstr(digit_buffer)) {
</ins><span class="cx">                 switch_channel_set_variable(channel, var_name, digit_buffer);
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1721,8 +1721,8 @@
</span><span class="cx">                 }
</span><span class="cx">
</span><span class="cx">                 if (status == SWITCH_STATUS_SUCCESS) {
</span><del>-                        if (!switch_strlen_zero(digit_buffer)) {
-                                if (switch_strlen_zero(digits_regex)) {
</del><ins>+                        if (!zstr(digit_buffer)) {
+                                if (zstr(digits_regex)) {
</ins><span class="cx">                                         return SWITCH_STATUS_SUCCESS;
</span><span class="cx">                                 }
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_DEBUG, "Test Regex [%s][%s]\n", digit_buffer, digits_regex);
</span><span class="lines">@@ -2217,7 +2217,7 @@
</span><span class="cx">                                 moh = switch_channel_get_variable(other_channel, "hold_music");
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (!switch_strlen_zero(moh) && strcasecmp(moh, "silence") && !switch_channel_test_flag(other_channel, CF_BROADCAST)) {
</del><ins>+                        if (!zstr(moh) && strcasecmp(moh, "silence") && !switch_channel_test_flag(other_channel, CF_BROADCAST)) {
</ins><span class="cx">                                 switch_ivr_broadcast(other_uuid, moh, SMF_ECHO_ALEG | SMF_LOOP);
</span><span class="cx">                                 moh_br++;
</span><span class="cx">                         }
</span><span class="lines">@@ -2228,7 +2228,7 @@
</span><span class="cx">                                 moh = switch_channel_get_variable(channel, "hold_music");
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (!switch_strlen_zero(moh) && strcasecmp(moh, "silence")) {
</del><ins>+                        if (!zstr(moh) && strcasecmp(moh, "silence")) {
</ins><span class="cx">                                 switch_ivr_play_file(session, NULL, moh, &args);
</span><span class="cx">                         } else {
</span><span class="cx">                                 switch_ivr_collect_digits_callback(session, &args, 0, 0);
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_loadable_modulec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_loadable_module.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_loadable_module.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_loadable_module.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -960,7 +960,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_status_t status;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(mod)) {
</del><ins>+        if (zstr(mod)) {
</ins><span class="cx">                 return SWITCH_STATUS_FALSE;
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -1166,7 +1166,7 @@
</span><span class="cx">                                 switch_bool_t global = SWITCH_FALSE;
</span><span class="cx">                                 const char *val = switch_xml_attr_soft(ld, "module");
</span><span class="cx">                                 const char *sglobal = switch_xml_attr_soft(ld, "global");
</span><del>-                                if (switch_strlen_zero(val) || (strchr(val, '.') && !strstr(val, ext) && !strstr(val, EXT))) {
</del><ins>+                                if (zstr(val) || (strchr(val, '.') && !strstr(val, ext) && !strstr(val, EXT))) {
</ins><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "Invalid extension for %s\n", val);
</span><span class="cx">                                         continue;
</span><span class="cx">                                 }
</span><span class="lines">@@ -1189,7 +1189,7 @@
</span><span class="cx">                                 switch_bool_t global = SWITCH_FALSE;
</span><span class="cx">                                 const char *val = switch_xml_attr_soft(ld, "module");
</span><span class="cx">                                 const char *sglobal = switch_xml_attr_soft(ld, "global");
</span><del>-                                if (switch_strlen_zero(val) || (strchr(val, '.') && !strstr(val, ext) && !strstr(val, EXT))) {
</del><ins>+                                if (zstr(val) || (strchr(val, '.') && !strstr(val, ext) && !strstr(val, EXT))) {
</ins><span class="cx">                                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CONSOLE, "Invalid extension for %s\n", val);
</span><span class="cx">                                         continue;
</span><span class="cx">                                 }
</span><span class="lines">@@ -1230,7 +1230,7 @@
</span><span class="cx">                                 continue;
</span><span class="cx">                         }
</span><span class="cx">
</span><del>-                        if (switch_strlen_zero(fname) || (!strstr(fname, ext) && !strstr(fname, EXT))) {
</del><ins>+                        if (zstr(fname) || (!strstr(fname, ext) && !strstr(fname, EXT))) {
</ins><span class="cx">                                 continue;
</span><span class="cx">                         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_logc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_log.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_log.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_log.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -103,12 +103,12 @@
</span><span class="cx">         
</span><span class="cx">         *newnode = *node;
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(node->data)) {
</del><ins>+        if (!zstr(node->data)) {
</ins><span class="cx">                 newnode->data = strdup(node->data);        
</span><span class="cx">                 switch_assert(node->data);
</span><span class="cx">         }
</span><span class="cx">         
</span><del>-        if (!switch_strlen_zero(node->userdata)) {
</del><ins>+        if (!zstr(node->userdata)) {
</ins><span class="cx">                 newnode->userdata = strdup(node->userdata);
</span><span class="cx">                 switch_assert(node->userdata);
</span><span class="cx">         }
</span><span class="lines">@@ -398,7 +398,7 @@
</span><span class="cx">                         switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "Log-Function", funcp);
</span><span class="cx">                         switch_event_add_header(event, SWITCH_STACK_BOTTOM, "Log-Line", "%d", line);
</span><span class="cx">                         switch_event_add_header(event, SWITCH_STACK_BOTTOM, "Log-Level", "%d", (int) level);
</span><del>-                        if (!switch_strlen_zero(userdata)) {
</del><ins>+                        if (!zstr(userdata)) {
</ins><span class="cx">                                 switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "User-Data", userdata);
</span><span class="cx">                         }
</span><span class="cx">                         switch_event_fire(&event);
</span><span class="lines">@@ -458,7 +458,7 @@
</span><span class="cx">                 node->content = content;
</span><span class="cx">                 node->timestamp = now;
</span><span class="cx">                 node->channel = channel;
</span><del>-                node->userdata = !switch_strlen_zero(userdata) ? strdup(userdata) : NULL;
</del><ins>+                node->userdata = !zstr(userdata) ? strdup(userdata) : NULL;
</ins><span class="cx">
</span><span class="cx">                 if (switch_queue_trypush(LOG_QUEUE, node) != SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                         switch_log_node_free(&node);
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_natc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_nat.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_nat.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_nat.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -69,7 +69,7 @@
</span><span class="cx">         if (UPNP_GetExternalIPAddress(nat_globals.urls.controlURL,
</span><span class="cx">                                                                  nat_globals.data.servicetype,
</span><span class="cx">                                                                  pub_addr) == UPNPCOMMAND_SUCCESS) {
</span><del>-                if (!strcmp(pub_addr, "0.0.0.0") || switch_strlen_zero_buf(pub_addr)) {
</del><ins>+                if (!strcmp(pub_addr, "0.0.0.0") || zstr_buf(pub_addr)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR,
</span><span class="cx">                                                          "uPNP Device (url: %s) returned an invalid external address of '%s'. Disabling uPNP\n", nat_globals.urls.controlURL, pub_addr);
</span><span class="cx">                         return SWITCH_STATUS_GENERR;
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_odbcc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_odbc.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_odbc.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_odbc.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -524,7 +524,7 @@
</span><span class="cx">         
</span><span class="cx">         if (stmt) {
</span><span class="cx">                 err_str = switch_odbc_handle_get_error(handle, stmt);
</span><del>-                if (!switch_strlen_zero(err_str)) {
</del><ins>+                if (!zstr(err_str)) {
</ins><span class="cx">                         switch_log_printf(SWITCH_CHANNEL_ID_LOG, file, func, line, NULL, SWITCH_LOG_ERROR, "ERR: [%s]\n[%s]\n", sql, switch_str_nil(err_str));
</span><span class="cx">                 }
</span><span class="cx">                 switch_safe_free(err_str);
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_rtpc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_rtp.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_rtp.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_rtp.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -765,7 +765,7 @@
</span><span class="cx">
</span><span class="cx">         *err = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(host) || !port) {
</del><ins>+        if (zstr(host) || !port) {
</ins><span class="cx">                 *err = "Address Error";
</span><span class="cx">                 goto done;
</span><span class="cx">         }
</span><span class="lines">@@ -869,7 +869,7 @@
</span><span class="cx">
</span><span class="cx"> SWITCH_DECLARE(char *) switch_rtp_get_remote_host(switch_rtp_t *rtp_session)
</span><span class="cx"> {
</span><del>-        return switch_strlen_zero(rtp_session->remote_host_str) ? "0.0.0.0" : rtp_session->remote_host_str;
</del><ins>+        return zstr(rtp_session->remote_host_str) ? "0.0.0.0" : rtp_session->remote_host_str;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> SWITCH_DECLARE(switch_port_t) switch_rtp_get_remote_port(switch_rtp_t *rtp_session)
</span><span class="lines">@@ -1138,15 +1138,15 @@
</span><span class="cx">         switch_rtp_set_interval(rtp_session, ms_per_packet, samples_per_interval);
</span><span class="cx">         rtp_session->conf_samples_per_interval = samples_per_interval;
</span><span class="cx">
</span><del>-        if (switch_test_flag(rtp_session, SWITCH_RTP_FLAG_USE_TIMER) && switch_strlen_zero(timer_name)) {
</del><ins>+        if (switch_test_flag(rtp_session, SWITCH_RTP_FLAG_USE_TIMER) && zstr(timer_name)) {
</ins><span class="cx">                 timer_name = "soft";
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(timer_name) && !strcasecmp(timer_name, "none")) {
</del><ins>+        if (!zstr(timer_name) && !strcasecmp(timer_name, "none")) {
</ins><span class="cx">                 timer_name = NULL;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(timer_name)) {
</del><ins>+        if (!zstr(timer_name)) {
</ins><span class="cx">                 rtp_session->timer_name = switch_core_strdup(pool, timer_name);
</span><span class="cx">                 switch_set_flag_locked(rtp_session, SWITCH_RTP_FLAG_USE_TIMER);
</span><span class="cx">                 switch_set_flag_locked(rtp_session, SWITCH_RTP_FLAG_NOBLOCK);
</span><span class="lines">@@ -1229,7 +1229,7 @@
</span><span class="cx"> {
</span><span class="cx">         switch_rtp_t *rtp_session = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(rx_host)) {
</del><ins>+        if (zstr(rx_host)) {
</ins><span class="cx">                 *err = "Missing local host";
</span><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="lines">@@ -1239,7 +1239,7 @@
</span><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(tx_host)) {
</del><ins>+        if (zstr(tx_host)) {
</ins><span class="cx">                 *err = "Missing remote host";
</span><span class="cx">                 goto end;
</span><span class="cx">         }
</span><span class="lines">@@ -1901,7 +1901,7 @@
</span><span class="cx">                                         const char *err;
</span><span class="cx">                                         uint32_t old = rtp_session->remote_port;
</span><span class="cx">                                         
</span><del>-                                        if (!switch_strlen_zero(tx_host) && switch_sockaddr_get_port(rtp_session->from_addr) > 0) {
</del><ins>+                                        if (!zstr(tx_host) && switch_sockaddr_get_port(rtp_session->from_addr) > 0) {
</ins><span class="cx">                                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO,
</span><span class="cx">                                                                                  "Auto Changing port from %s:%u to %s:%u\n", old_host, old, tx_host,
</span><span class="cx">                                                                                  switch_sockaddr_get_port(rtp_session->from_addr));
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_schedulerc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_scheduler.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_scheduler.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_scheduler.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -263,7 +263,7 @@
</span><span class="cx">
</span><span class="cx">         switch_mutex_lock(globals.task_mutex);
</span><span class="cx">         for (tp = globals.task_list; tp; tp = tp->next) {
</span><del>-                if (!switch_strlen_zero(group) && !strcmp(tp->task.group, group)) {
</del><ins>+                if (!zstr(group) && !strcmp(tp->task.group, group)) {
</ins><span class="cx">                         if (switch_test_flag(tp, SSHF_NO_DEL)) {
</span><span class="cx">                                 switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "Attempt made to delete undeletable task #%u (group %s)\n",
</span><span class="cx">                                                                  tp->task.task_id, group);
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_swigc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_swig.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_swig.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_swig.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -49,7 +49,7 @@
</span><span class="cx">         switch_status_t status;
</span><span class="cx">         const char *err = NULL;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(path)) {
</del><ins>+        if (zstr(path)) {
</ins><span class="cx">                 path = NULL;
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_timec"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_time.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_time.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_time.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -640,11 +640,11 @@
</span><span class="cx">                                 const char *name = switch_xml_attr(x_list, "name");
</span><span class="cx">                                 const char *value= switch_xml_attr(x_list, "value");
</span><span class="cx">
</span><del>-                                if (switch_strlen_zero(name)) {
</del><ins>+                                if (zstr(name)) {
</ins><span class="cx">                                         continue;
</span><span class="cx">                                 }
</span><span class="cx">
</span><del>-                                if (switch_strlen_zero(value)) {
</del><ins>+                                if (zstr(value)) {
</ins><span class="cx">                                         continue;
</span><span class="cx">                                 }
</span><span class="cx">
</span><span class="lines">@@ -683,7 +683,7 @@
</span><span class="cx">
</span><span class="cx">         timep = (thetime) / (int64_t) (1000000);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(tz_name)) {
</del><ins>+        if (!zstr(tz_name)) {
</ins><span class="cx">                 tzdef = switch_lookup_timezone( tz_name );
</span><span class="cx">         } else {
</span><span class="cx">                 /* We set the default timezone to GMT. */
</span><span class="lines">@@ -719,7 +719,7 @@
</span><span class="cx">
</span><span class="cx">         timep = (thetime) / (int64_t) (1000000);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(tz_name)) {
</del><ins>+        if (!zstr(tz_name)) {
</ins><span class="cx">                 tzdef = switch_lookup_timezone( tz_name );
</span><span class="cx">         } else {
</span><span class="cx">                 /* We set the default timezone to GMT. */
</span><span class="lines">@@ -730,8 +730,8 @@
</span><span class="cx">         if (tzdef) { /* The lookup of the zone may fail. */
</span><span class="cx">                 tztime( &timep, tzdef, &tm );
</span><span class="cx">                 tm2switchtime( &tm, &stm );
</span><del>-                switch_strftime_nocheck(date, &retsize, len, switch_strlen_zero(format) ? "%Y-%m-%d %T" : format, &stm);
-                if (!switch_strlen_zero_buf(date)) {
</del><ins>+                switch_strftime_nocheck(date, &retsize, len, zstr(format) ? "%Y-%m-%d %T" : format, &stm);
+                if (!zstr_buf(date)) {
</ins><span class="cx">                         return SWITCH_STATUS_SUCCESS;
</span><span class="cx">                 }
</span><span class="cx">         }
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_utilsc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_utils.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_utils.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_utils.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -181,7 +181,7 @@
</span><span class="cx">         node->bits = bits;
</span><span class="cx">         node->str = switch_core_strdup(list->pool, cidr_str);
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(token)) {
</del><ins>+        if (!zstr(token)) {
</ins><span class="cx">                 node->token = switch_core_strdup(list->pool, token);
</span><span class="cx">         }
</span><span class="cx">         
</span><span class="lines">@@ -449,7 +449,7 @@
</span><span class="cx">         char *newfile = NULL;
</span><span class="cx">         switch_bool_t rval = SWITCH_FALSE;
</span><span class="cx">
</span><del>-        if (!switch_strlen_zero(file) && !switch_strlen_zero(convert_cmd) && !switch_strlen_zero(convert_ext)) {
</del><ins>+        if (!zstr(file) && !zstr(convert_cmd) && !zstr(convert_ext)) {
</ins><span class="cx">                 if ((ext = strrchr(file, '.'))) {
</span><span class="cx">                         dupfile = strdup(file);
</span><span class="cx">                         if ((ext = strrchr(dupfile, '.'))) {
</span><span class="lines">@@ -580,7 +580,7 @@
</span><span class="cx">                 close(ifd);
</span><span class="cx">         }
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(from)) {
</del><ins>+        if (zstr(from)) {
</ins><span class="cx">                 from = "freeswitch";
</span><span class="cx">         }
</span><span class="cx">
</span><span class="lines">@@ -617,7 +617,7 @@
</span><span class="cx">
</span><span class="cx"> SWITCH_DECLARE(switch_bool_t) switch_is_lan_addr(const char *ip)
</span><span class="cx"> {
</span><del>-        if (switch_strlen_zero(ip))
</del><ins>+        if (zstr(ip))
</ins><span class="cx">                 return SWITCH_FALSE;
</span><span class="cx">
</span><span class="cx">         return (strncmp(ip, "10.", 3) &&
</span><span class="lines">@@ -1824,7 +1824,7 @@
</span><span class="cx">         char *o;
</span><span class="cx">         unsigned int tmp;
</span><span class="cx">
</span><del>-        if (switch_strlen_zero(s)) {
</del><ins>+        if (zstr(s)) {
</ins><span class="cx">                 return s;
</span><span class="cx">         }
</span><span class="cx">
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_xmlc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_xml.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_xml.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_xml.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -1551,7 +1551,7 @@
</span><span class="cx">                         const char *err = NULL;
</span><span class="cx">
</span><span class="cx">                         err = switch_xml_error(xml);
</span><del>-                        if (switch_strlen_zero(err)) {
</del><ins>+                        if (zstr(err)) {
</ins><span class="cx">                                 if ((conf = switch_xml_find_child(xml, "section", "name", "result"))) {
</span><span class="cx">                                         switch_xml_t p;
</span><span class="cx">                                         const char *aname;
</span><span class="lines">@@ -1890,7 +1890,7 @@
</span><span class="cx">                 *err = switch_xml_error(new_main);
</span><span class="cx">                 switch_copy_string(not_so_threadsafe_error_buffer, *err, sizeof(not_so_threadsafe_error_buffer));
</span><span class="cx">                 *err = not_so_threadsafe_error_buffer;
</span><del>-                if (!switch_strlen_zero(*err)) {
</del><ins>+                if (!zstr(*err)) {
</ins><span class="cx">                         switch_xml_free(new_main);
</span><span class="cx">                         new_main = NULL;
</span><span class="cx">                         errcnt++;
</span></span></pre></div>
<a id="freeswitchtrunksrcswitch_xml_configc"></a>
<div class="modfile"><h4>Modified: freeswitch/trunk/src/switch_xml_config.c (15210 => 15211)</h4>
<pre class="diff"><span>
<span class="info">--- freeswitch/trunk/src/switch_xml_config.c        2009-10-23 15:50:51 UTC (rev 15210)
+++ freeswitch/trunk/src/switch_xml_config.c        2009-10-23 16:03:42 UTC (rev 15211)
</span><span class="lines">@@ -208,7 +208,7 @@
</span><span class="cx">                                         
</span><span class="cx">                                         /* Perform validation */
</span><span class="cx">                                         if (value) {
</span><del>-                                                if (!switch_strlen_zero(string_options->validation_regex)) {
</del><ins>+                                                if (!zstr(string_options->validation_regex)) {
</ins><span class="cx">                                                         if (switch_regex_match(value, string_options->validation_regex) == SWITCH_STATUS_SUCCESS) {
</span><span class="cx">                                                                 newstring = value; /* Regex match, accept value*/
</span><span class="cx">                                                         } else {
</span></span></pre>
</div>
</div>
<div id="footer">See you at ClueCon</div>
</body>
</html>