[Asterisk-code-review] chan sip.c: Validation on module reload (asterisk[master])
Rodrigo Ramirez Norambuena
asteriskteam at digium.com
Fri Aug 21 21:59:10 CDT 2015
Rodrigo Ramirez Norambuena has uploaded a new change for review.
https://gerrit.asterisk.org/1126
Change subject: chan_sip.c: Validation on module reload
......................................................................
chan_sip.c: Validation on module reload
Change validation on reload module because now used the cli function for
reload. Used defined values for return AST_MODULE_LOAD_SUCCESS and
AST_MODULE_LOAD_DECLINE instance of 0 and 1.
This problem is dectected on reload by PUT method on ARI, getting always
404 http code when the module is reloaded.
ASTERISK-25325 #close
Reporte by: Rodrigo Ramírez Norambuena
Change-Id: I41215877fb2cfc589e0d4d464000cf6825f4d7fb
---
M channels/chan_sip.c
1 file changed, 3 insertions(+), 3 deletions(-)
git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/26/1126/1
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 1888091..a57550b 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -33153,10 +33153,10 @@
/*! \brief Part of Asterisk module interface */
static int reload(void)
{
- if (sip_reload(0, 0, NULL)) {
- return 0;
+ if (sip_reload(0, 0, NULL) == CLI_SUCCESS) {
+ return AST_MODULE_LOAD_SUCCESS;
}
- return 1;
+ return AST_MODULE_LOAD_DECLINE;
}
/*! \brief Return the first entry from ast_sockaddr_resolve filtered by address family
--
To view, visit https://gerrit.asterisk.org/1126
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I41215877fb2cfc589e0d4d464000cf6825f4d7fb
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Rodrigo Ramirez Norambuena <a at rodrigoramirez.com>
More information about the asterisk-code-review
mailing list