Fix output of sipshowpeer manager response.
authorJason Parker <jparker@digium.com>
Wed, 20 Aug 2008 22:06:40 +0000 (22:06 +0000)
committerJason Parker <jparker@digium.com>
Wed, 20 Aug 2008 22:06:40 +0000 (22:06 +0000)
(closes issue #13346)
Reported by: srt
Patches:
      13346_malformed_sip_show_peer_response.diff uploaded by srt (license 378)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@139210 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_sip.c

index 01cca05..48360ad 100644 (file)
@@ -13244,12 +13244,11 @@ static char *_sip_show_peer(int type, int fd, struct mansession *s, const struct
                peer_status(peer, status, sizeof(status));
                astman_append(s, "%s\r\n", status);
                astman_append(s, "SIP-Useragent: %s\r\n", peer->useragent);
                peer_status(peer, status, sizeof(status));
                astman_append(s, "%s\r\n", status);
                astman_append(s, "SIP-Useragent: %s\r\n", peer->useragent);
-               astman_append(s, "Reg-Contact : %s\r\n", peer->fullcontact);
-               astman_append(s, "QualifyFreq : %d ms\n", peer->qualifyfreq);
+               astman_append(s, "Reg-Contact: %s\r\n", peer->fullcontact);
+               astman_append(s, "QualifyFreq: %d ms\r\n", peer->qualifyfreq);
                if (peer->chanvars) {
                        for (v = peer->chanvars ; v ; v = v->next) {
                if (peer->chanvars) {
                        for (v = peer->chanvars ; v ; v = v->next) {
-                               astman_append(s, "ChanVariable:\n");
-                               astman_append(s, " %s,%s\r\n", v->name, v->value);
+                               astman_append(s, "ChanVariable: %s=%s\r\n", v->name, v->value);
                        }
                }
 
                        }
                }