[Asterisk-code-review] Extends ami call back of sip unregister to add the ip addres... (asterisk[master])

Peter Katzmann asteriskteam at digium.com
Wed Jun 3 04:03:19 CDT 2015


Peter Katzmann has uploaded a new change for review.

  https://gerrit.asterisk.org/575

Change subject: Extends ami call back of sip unregister to add the ip address of the endpoint
......................................................................

Extends ami call back of sip unregister to add the ip address of the endpoint

Change-Id: I289bbff01ef4e55072c3f5f2d580f11b350bedd6
---
M channels/chan_sip.c
1 file changed, 3 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/75/575/1

diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 7c4c8a6..dac392b 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -15900,9 +15900,10 @@
 	if (peer->endpoint) {
 		RAII_VAR(struct ast_json *, blob, NULL, ast_json_unref);
 		ast_endpoint_set_state(peer->endpoint, AST_ENDPOINT_OFFLINE);
-		blob = ast_json_pack("{s: s, s: s}",
+		blob = ast_json_pack("{s: s, s: s, s: s}",
 			"peer_status", "Unregistered",
-			"cause", "Expired");
+			"cause", "Expired"
+			"address", ast_sockaddr_stringify(&peer->addr));
 		ast_endpoint_blob_publish(peer->endpoint, ast_endpoint_state_type(), blob);
 	}
 	register_peer_exten(peer, FALSE);	/* Remove regexten */

-- 
To view, visit https://gerrit.asterisk.org/575
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I289bbff01ef4e55072c3f5f2d580f11b350bedd6
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Peter Katzmann <peter.katzmann at edag.de>



More information about the asterisk-code-review mailing list