change switch_strlen_zero to zstr

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@15211 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale committed 2009-10-23 16:03:42 +00:00
1 parent 410b6ebd1f
commit df7637f687
96 files changed
+1033 -1033

No files matched your search

+2 -2
View File
@@ -130,7 +130,7 @@ static switch_status_t config_logger(void)
#else
COLORIZE = 1;
#endif
} else if (!strcasecmp(var, "loglevel") && !switch_strlen_zero(val)) {
} else if (!strcasecmp(var, "loglevel") && !zstr(val)) {
hard_log_level = switch_log_str2level(val);
}
}
@@ -289,7 +289,7 @@ SWITCH_STANDARD_API(console_api_function)
if (session)
return SWITCH_STATUS_FALSE;
if (switch_strlen_zero(cmd)) {
if (zstr(cmd)) {
stream->write_function(stream, "%s", usage_string);
goto done;
}
+1 -1
View File
@@ -277,7 +277,7 @@ static switch_status_t load_profile(switch_xml_t xml)
}
}
if (switch_strlen_zero(new_profile->logfile)) {
if (zstr(new_profile->logfile)) {
char logfile[512];
switch_snprintf(logfile, sizeof(logfile), "%s%s%s", SWITCH_GLOBAL_dirs.log_dir, SWITCH_PATH_SEPARATOR, "freeswitch.log");
new_profile->logfile = strdup(logfile);
+5 -5
View File
@@ -101,7 +101,7 @@ static switch_status_t mod_syslog_logger(const switch_log_node_t *node, switch_l
}
/* don't log blank lines */
if (!switch_strlen_zero(node->data) && (strspn(node->data, " \t\r\n") < strlen(node->data))) {
if (!zstr(node->data) && (strspn(node->data, " \t\r\n") < strlen(node->data))) {
syslog(syslog_level, "%s", node->data);
}
@@ -130,7 +130,7 @@ static switch_status_t load_config(void)
set_global_format(val);
} else if (!strcmp(var, "facility")) {
set_global_facility(val);
} else if (!strcasecmp(var, "loglevel") && !switch_strlen_zero(val)) {
} else if (!strcasecmp(var, "loglevel") && !zstr(val)) {
log_level = switch_log_str2level(val);
if (log_level == SWITCH_LOG_INVALID) {
log_level = SWITCH_LOG_WARNING;
@@ -142,13 +142,13 @@ static switch_status_t load_config(void)
switch_xml_free(xml);
}
if (switch_strlen_zero(globals.ident)) {
if (zstr(globals.ident)) {
set_global_ident(DEFAULT_IDENT);
}
if (switch_strlen_zero(globals.format)) {
if (zstr(globals.format)) {
set_global_format(DEFAULT_FORMAT);
}
if (switch_strlen_zero(globals.facility)) {
if (zstr(globals.facility)) {
set_global_facility(DEFAULT_FACILITY);
}
return 0;