don't print null in show commands return values.

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4166 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Michael Jerris 2007-02-08 18:10:21 +00:00
parent b650424da0
commit d8f906850b
1 changed files with 2 additions and 2 deletions

View File

@ -590,9 +590,9 @@ static int show_callback(void *pArg, int argc, char **argv, char **columnNames){
for(x = 0; x < argc; x++) {
if (holder->http) {
holder->stream->write_function(holder->stream, "<td>");
holder->stream->write_function(holder->stream, "%s%s", argv[x], x == (argc - 1) ? "</td></tr>\n" : "</td><td>");
holder->stream->write_function(holder->stream, "%s%s", argv[x] ? argv[x] : "", x == (argc - 1) ? "</td></tr>\n" : "</td><td>");
} else {
holder->stream->write_function(holder->stream, "%s%s", argv[x], x == (argc - 1) ? "\n" : ",");
holder->stream->write_function(holder->stream, "%s%s", argv[x] ? argv[x] : "", x == (argc - 1) ? "\n" : ",");
}
}