[Asterisk-code-review] Delete unneeded check in chan sip (asterisk[master])
Badalian Vyacheslav
asteriskteam at digium.com
Thu Dec 8 12:55:04 CST 2016
Badalian Vyacheslav has uploaded a new change for review. ( https://gerrit.asterisk.org/4597 )
Change subject: Delete unneeded check in chan_sip
......................................................................
Delete unneeded check in chan_sip
P is always true. We check it before
Change-Id: Iee61cda002a9f61aee26b9f66c5f9b59e3389efb
---
M channels/chan_sip.c
1 file changed, 3 insertions(+), 4 deletions(-)
git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/97/4597/1
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 7f22b96..3627fb9 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -6885,10 +6885,9 @@
ast_log(LOG_ERROR, "update_call_counter(%s, %d) called with no event!\n", name, event);
}
- if (p) {
- ast_devstate_changed(AST_DEVICE_UNKNOWN, AST_DEVSTATE_CACHABLE, "SIP/%s", p->name);
- sip_unref_peer(p, "update_call_counter: sip_unref_peer from call counter");
- }
+ ast_devstate_changed(AST_DEVICE_UNKNOWN, AST_DEVSTATE_CACHABLE, "SIP/%s", p->name);
+ sip_unref_peer(p, "update_call_counter: sip_unref_peer from call counter");
+
return 0;
}
--
To view, visit https://gerrit.asterisk.org/4597
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Iee61cda002a9f61aee26b9f66c5f9b59e3389efb
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Badalian Vyacheslav <v.badalyan at open-bs.ru>
More information about the asterisk-code-review
mailing list