Module: sip-router
Branch: 3.1
Commit: 0299c9e29cd51b9c0fba8cdad0e1354e95f4c17c
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=0299c9e…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Sun Feb 27 16:40:37 2011 +0100
core: framework for generic free of parsed headers
- the structure of parsed headers can define as first field a function
to free the content
- this allow to implement the parser for headers our of the core
(cherry picked from commit 81d05af470d979b3d3f104bbdaa287b3fa58b57c)
---
parser/hf.c | 3 +++
parser/hf.h | 7 +++++++
2 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/parser/hf.c b/parser/hf.c
index fe6b7a7..8863a10 100644
--- a/parser/hf.c
+++ b/parser/hf.c
@@ -130,6 +130,9 @@ void clean_hdr_field(struct hdr_field* hf)
break;
case HDR_SUPPORTED_T:
+ if(*h_parsed) {
+ ((hf_parsed_t*)(*h_parsed))->hfree(*h_parsed);
+ }
break;
case HDR_REQUIRE_T:
diff --git a/parser/hf.h b/parser/hf.h
index f496e9a..035c91c 100644
--- a/parser/hf.h
+++ b/parser/hf.h
@@ -213,6 +213,13 @@ typedef struct hdr_field {
} hdr_field_t;
+/* type of the function to free the structure of parsed header field */
+typedef void (*hf_parsed_free_f)(void *parsed);
+
+/* structure to hold the function to free the parsed header field */
+typedef struct hdr_parsed {
+ hf_parsed_free_f hfree;
+} hf_parsed_t;
/** returns true if the header links allocated memory on parse field. */
static inline int hdr_allocs_parse(struct hdr_field* hdr)
Module: sip-router
Branch: master
Commit: 81d05af470d979b3d3f104bbdaa287b3fa58b57c
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=81d05af…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Sun Feb 27 16:40:37 2011 +0100
core: framework for generic free of parsed headers
- the structure of parsed headers can define as first field a function
to free the content
- this allow to implement the parser for headers our of the core
---
parser/hf.c | 3 +++
parser/hf.h | 7 +++++++
2 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/parser/hf.c b/parser/hf.c
index fe6b7a7..8863a10 100644
--- a/parser/hf.c
+++ b/parser/hf.c
@@ -130,6 +130,9 @@ void clean_hdr_field(struct hdr_field* hf)
break;
case HDR_SUPPORTED_T:
+ if(*h_parsed) {
+ ((hf_parsed_t*)(*h_parsed))->hfree(*h_parsed);
+ }
break;
case HDR_REQUIRE_T:
diff --git a/parser/hf.h b/parser/hf.h
index f496e9a..035c91c 100644
--- a/parser/hf.h
+++ b/parser/hf.h
@@ -213,6 +213,13 @@ typedef struct hdr_field {
} hdr_field_t;
+/* type of the function to free the structure of parsed header field */
+typedef void (*hf_parsed_free_f)(void *parsed);
+
+/* structure to hold the function to free the parsed header field */
+typedef struct hdr_parsed {
+ hf_parsed_free_f hfree;
+} hf_parsed_t;
/** returns true if the header links allocated memory on parse field. */
static inline int hdr_allocs_parse(struct hdr_field* hdr)
Hello Community,
I am new to Kamailio, and this list as well.
I am trying to install Kamailio 3.1.2, but I am getting too many errors. I
have fixed some but still not getting the way.
I am using Red Hat Enterprise Linux (RHEL) 5, and /usr/local directory.
When I ran the following command:
make group_include="standard standard-dep mysql"
include_modules="carrierroute peering" install
it prompted not found error for the file docbookx.dtd, I found it
(modules/auth/auth.xml, and modules_s/acc_syslog/acc_syslog.xml) and fixed
it as it was errorenous URL location.
For reference earlier it was
http://www.oasis-open.org/docbookid/id/g/4.5/docbookx.dtd, which I changed
to http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd.
Now when I run the previous command again, I am getting the follwing errors:
*nsgmls:<URL>http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd:116:17:E:
"X20AC" is not a function name*
If I ignore this, and continue, I am not able to find the "sip-router"
service in /etc/init.d.
The entire errors is attached here.
Please help me solve the issue.
TIA
Module: sip-router
Branch: master
Commit: f7b5a333d29579a700d636787550ff1430a58189
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=f7b5a33…
Author: Juha Heinanen <jh(a)tutpro.com>
Committer: Juha Heinanen <jh(a)tutpro.com>
Date: Sun Feb 27 06:54:44 2011 +0200
modules/dialplan: change in dp_translate return code
- dp_translate now returns -2 (instead of -1) if dp with given id does
not exist.
---
modules/dialplan/README | 3 +++
modules/dialplan/dialplan.c | 2 +-
modules/dialplan/doc/dialplan_admin.xml | 4 ++++
3 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/modules/dialplan/README b/modules/dialplan/README
index cf9d9d5..e03067d 100644
--- a/modules/dialplan/README
+++ b/modules/dialplan/README
@@ -334,6 +334,9 @@ modparam("dialplan", "fetch_rows", 4000)
with dialplan ID equal to id. If dest is missing, only matching and
storing of matching rule's attributes is done.
+ Returns 1, if translation succeeded, -1 in case of some error occurred,
+ and -2 if dialplan with ID equal to id does not exist.
+
Meaning of the parameters is as follows:
* id -the dialplan id of the possible matching rules. This parameter
can have the following types:
diff --git a/modules/dialplan/dialplan.c b/modules/dialplan/dialplan.c
index 4c86778..16050cc 100644
--- a/modules/dialplan/dialplan.c
+++ b/modules/dialplan/dialplan.c
@@ -326,7 +326,7 @@ static int dp_translate_f(struct sip_msg* msg, char* str1, char* str2)
if ((idp = select_dpid(dpid)) ==0 ){
LM_DBG("no information available for dpid %i\n", dpid);
- return -1;
+ return -2;
}
repl_par = (str2!=NULL)? ((dp_param_p)str2):default_par2;
diff --git a/modules/dialplan/doc/dialplan_admin.xml b/modules/dialplan/doc/dialplan_admin.xml
index ac9a84d..43c418b 100644
--- a/modules/dialplan/doc/dialplan_admin.xml
+++ b/modules/dialplan/doc/dialplan_admin.xml
@@ -365,6 +365,10 @@ modparam("dialplan", "fetch_rows", 4000)
missing, only matching and storing of matching rule's
attributes is done.
</para>
+ <para>
+ Returns 1, if translation succeeded, -1 in case of some error
+ occurred, and -2 if dialplan with ID equal to id does not exist.
+ </para>
<para>Meaning of the parameters is as follows:</para>
<itemizedlist>
<listitem>