rtpdebugaddr.sin_family = AF_INET;
memcpy(&rtpdebugaddr.sin_addr, hp->h_addr, sizeof(rtpdebugaddr.sin_addr));
rtpdebugaddr.sin_port = htons(port);
- if (port == 0)
+ if (port == 0) {
ast_cli(a->fd, "RTP Debugging Enabled for IP: %s\n", ast_inet_ntoa(rtpdebugaddr.sin_addr));
- else
+ } else {
ast_cli(a->fd, "RTP Debugging Enabled for IP: %s:%d\n", ast_inet_ntoa(rtpdebugaddr.sin_addr), port);
+ }
rtpdebug = 1;
return CLI_SUCCESS;
}
struct hostent *hp;
struct ast_hostent ahp;
int port = 0;
- char *p, *arg = ast_strdupa(a->argv[3]);
+ char *p, *arg = ast_strdupa(a->argv[4]);
p = strstr(arg, ":");
if (p) {
rtcpdebugaddr.sin_family = AF_INET;
memcpy(&rtcpdebugaddr.sin_addr, hp->h_addr, sizeof(rtcpdebugaddr.sin_addr));
rtcpdebugaddr.sin_port = htons(port);
- if (port == 0)
+ if (port == 0) {
ast_cli(a->fd, "RTCP Debugging Enabled for IP: %s\n", ast_inet_ntoa(rtcpdebugaddr.sin_addr));
- else
+ } else {
ast_cli(a->fd, "RTCP Debugging Enabled for IP: %s:%d\n", ast_inet_ntoa(rtcpdebugaddr.sin_addr), port);
+ }
rtcpdebug = 1;
return CLI_SUCCESS;
}