Module: kamailio
Branch: master
Commit: 2fe8749ab7bd7622d46a57ab88f90e35bb7b0164
URL: https://github.com/kamailio/kamailio/commit/2fe8749ab7bd7622d46a57ab88f90e3…
Author: alezzandro <alezzandro(a)gmail.com>
Committer: alezzandro <alezzandro(a)gmail.com>
Date: 2015-01-09T16:59:11+01:00
dispatcher: Corrected comments indentation
---
Modified: modules/dispatcher/dispatch.h
---
Diff: https://github.com/kamailio/kamailio/commit/2fe8749ab7bd7622d46a57ab88f90e3…
Patch: https://github.com/kamailio/kamailio/commit/2fe8749ab7bd7622d46a57ab88f90e3…
---
diff --git a/modules/dispatcher/dispatch.h b/modules/dispatcher/dispatch.h
index 29f2ec7..d991fd7 100644
--- a/modules/dispatcher/dispatch.h
+++ b/modules/dispatcher/dispatch.h
@@ -102,8 +102,10 @@ extern pv_spec_t ds_attrs_pv;
extern struct tm_binds tmb;
extern str ds_ping_method;
extern str ds_ping_from;
-extern int probing_threshold; /*!< number of failed requests, before a destination is taken into probing */
-extern int inactive_threshold; /*!< number of successful requests, before a destination is taken into active */
+extern int probing_threshold; /*!< number of failed requests,
+ before a destination is taken into probing */
+extern int inactive_threshold; /*!< number of successful requests,
+ before a destination is taken into active */
extern int ds_probing_mode;
extern str ds_outbound_proxy;
extern str ds_default_socket;
First of all excuse me if in the previous pull request I didn't follow guidelines by devel-git-commit guide :)
As anticipated in the previous request I made some changes to dispatcher module for counting successful ping requests before moving a destination from inactive to active state.
While doing this changes I noticed some misspelled variables (in code and docs too) and I fixed them. So I've used similar variables (with the corrected words) also for the new feature I developed.
In the case we leave the old variables introducing the new one we will have in the code:
"ds_probing_threshhold" vs "ds_inactive_threshold"
This behaviour could be confusing while editing the configuration file and also while reading the code.
As you requested I've separated the misspelled fixes in two commits one for the code and one for the docs.
To this pull request will follow the one with the changes developing the new feature.
You can merge this Pull Request by running:
git pull https://github.com/alezzandro/kamailio master
Or you can view, comment on it, or merge it online at:
https://github.com/kamailio/kamailio/pull/13
-- Commit Summary --
* dispatcher: Fixing misspelled words in some code's variables
* dispatcher: Fixing misspelled words in some docs
-- File Changes --
M modules/dispatcher/README (12)
M modules/dispatcher/config.c (4)
M modules/dispatcher/config.h (2)
M modules/dispatcher/dispatch.c (5)
M modules/dispatcher/dispatch.h (3)
M modules/dispatcher/dispatcher.c (11)
M modules/dispatcher/doc/dispatcher_admin.xml (4)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/13.patchhttps://github.com/kamailio/kamailio/pull/13.diff
---
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/13
Hi All,
Can anyone see a problem with doing (something like) the following, to
handle the situation like
http://lists.sip-router.org/pipermail/sr-users/2014-October/085251.html?
Admittedly, it is probably a less common use case, but it has been raised
several times on the list so I believe it is a genuine one.
diff --git a/modules/registrar/lookup.c b/modules/registrar/lookup.c
index 794d968..66730b4 100644
--- a/modules/registrar/lookup.c
+++ b/modules/registrar/lookup.c
@@ -41,6 +41,7 @@
#include "../../action.h"
#include "../../mod_fix.h"
#include "../../parser/parse_rr.h"
+#include "../../forward.h"
#include "../usrloc/usrloc.h"
#include "common.h"
#include "regtime.h"
@@ -121,6 +122,7 @@ int lookup_helper(struct sip_msg* _m, udomain_t* _d,
str* _uri, int _mode)
sr_xavp_t *list=NULL;
str xname = {"ruid", 4};
sr_xval_t xval;
+ sip_uri_t path_uri;
ret = -1;
@@ -265,6 +267,14 @@ int lookup_helper(struct sip_msg* _m, udomain_t* _d,
str* _uri, int _mode)
ret = -3;
goto done;
}
+ if (parse_uri(path_dst.s, path_dst.len, &path_uri)
< 0){
+ LM_ERR("failed to parse the Path URI\n");
+ ret = -3;
+ goto done;
+ }
+ }
+ /* Only use path-uri if non-local */
+ if (path_uri.host.s && !check_self(&(path_uri.host), 0, 0))
{
if (set_path_vector(_m, &ptr->path) < 0) {
LM_ERR("failed to set path vector\n");
ret = -3;
The above needs to be repeated in lookup_branches function of same file,
but I wanted to check others' opinions first.
Best regards,
Charles
--
www.sipcentric.com
Follow us on twitter @sipcentric <http://twitter.com/sipcentric>
Sipcentric Ltd. Company registered in England & Wales no. 7365592. Registered
office: Faraday Wharf, Innovation Birmingham Campus, Holt Street,
Birmingham Science Park, Birmingham B7 4BB.