Call IDs: Fix appearance of call ID in core show channels when NULL

NULL call IDs were meant to appear as '(none)' but instead were showing
the contents of an uninitialized character buffer.

ASTERISK-24223
Review: https://reviewboard.asterisk.org/r/3979/
........

Merged revisions 422664 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@422665 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Jonathan Rose
2014-09-05 17:55:35 +00:00
parent 3ce9a8b4f4
commit 43a35c2407

View File

@@ -1579,6 +1579,7 @@ static char *handle_showchan(struct ast_cli_entry *e, int cmd, struct ast_cli_ar
ast_translate_path_to_str(ast_channel_readtrans(chan), &read_transpath);
bridge = ast_channel_get_bridge(chan);
callid_buf[0] = '\0';
callid = ast_channel_callid(chan);
if (callid) {
ast_callid_strnprint(callid_buf, sizeof(callid_buf), callid);