提交 d8f90685 authored 作者: Michael Jerris's avatar Michael Jerris

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
上级 b650424d
...@@ -590,9 +590,9 @@ static int show_callback(void *pArg, int argc, char **argv, char **columnNames){ ...@@ -590,9 +590,9 @@ static int show_callback(void *pArg, int argc, char **argv, char **columnNames){
for(x = 0; x < argc; x++) { for(x = 0; x < argc; x++) {
if (holder->http) { if (holder->http) {
holder->stream->write_function(holder->stream, "<td>"); 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 { } 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" : ",");
} }
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论