THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.
The following task has a new comment added:
FS#404 - Coredump on using jsonrpc_request
User who did this - Daniel-Constantin Mierla (miconda)
----------
If you can reproduce it, can you send log messages with debug=3 in kamailio.cfg as well as the full backtrace from corefile taken with gdb?
----------
More information can be found at the following URL:
http://sip-router.org/tracker/index.php?do=details&task_id=404#comment1311
You are receiving this message because you have requested it from the Flyspray bugtracking system. If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.
THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.
A new Flyspray task has been opened. Details are below.
User who did this - davy van de moere (davyvdm)
Attached to Project - sip-router
Summary - Coredump on using jsonrpc_request
Task Type - Bug Report
Category - Module
Status - Unconfirmed
Assigned To -
Operating System - Linux
Severity - Medium
Priority - Normal
Reported Version - Development
Due in Version - Undecided
Due Date - Undecided
Details - I tried this with the branch 4.1 and master. Both behave identical.
So from the kamailio-basic.cfg example, I just added this line around line 350 (just above route(SIPOUT)):
jsonrpc_request("bar.sendsms", "{'ru':'$rU','rb':'$rb'}", "JSONRESPONSE", "JSONERROR", "$var(result)");
Doing a ngrep on the netstrings I have:
interface: venet0 (127.0.0.2/255.255.255.255)
filter: (ip or ip6) and ( port 7080 )
#
T 10.66.8.42:44995 -> 192.168.60.45:7080 [AP]
94:{ "id": 2, "jsonrpc": "2.0", "method": "bar.sendsms", "params": { "ru": "", "rb": "" } },
##
T 192.168.60.45:7080 -> 10.66.8.42:44995 [AP]
43:{"jsonrpc": "2.0", "result": "12", "id": 2},
####^Cexit
7 received, 0 dropped
I do get some results from the JSONRESPONSE route.
But when launching a call, or when sending just a register packet, kamailio gives up with:
Feb 26 06:29:11 SBC01 kamailio[18043]: WARNING: tm [t_lookup.c:1537]: t_unref(): WARNING: script writer didn't release transaction
Feb 26 06:29:12 SBC01 kamailio[18033]: : [mem/q_malloc.c:468]: qm_free(): BUG: qm_free: freeing already freed pointer (0xb4c01624), called from tm: h_table.c: free_cell(157), first free tm: h_table.c: free_cell(157) - aborting
Feb 26 06:29:12 SBC01 kamailio[18023]: ALERT: [main.c:775]: handle_sigs(): child process 18033 exited by a signal 6
Feb 26 06:29:12 SBC01 kamailio[18023]: ALERT: [main.c:778]: handle_sigs(): core was generated
Feb 26 06:29:12 SBC01 kamailio[18023]: INFO: [main.c:790]: handle_sigs(): INFO: terminating due to SIGCHLD
Feb 26 06:29:12 SBC01 kamailio[18041]: INFO: [main.c:841]: sig_usr(): INFO: signal 15 received
Feb 26 06:29:12 SBC01 kamailio[18047]: INFO: [main.c:841]: sig_usr(): INFO: signal 15 received
Feb 26 06:29:12 SBC01 kamailio[18043]: INFO: [main.c:841]: sig_usr(): INFO: signal 15 received
Feb 26 06:29:12 SBC01 kamailio[18048]: INFO: [main.c:841]: sig_usr(): INFO: signal 15 received
Feb 26 06:29:12 SBC01 kamailio[18023]: : [mem/q_malloc.c:468]: qm_free(): BUG: qm_free: freeing already freed pointer (0xb4c01624), called from tm: h_table.c: free_cell(157), first free tm: h_table.c: free_cell(157) - aborting
Using the jsonrpc_notification on the other hand works like a charm.
Coredump in attach.
One or more files have been attached.
More information can be found at the following URL:
http://sip-router.org/tracker/index.php?do=details&task_id=404
You are receiving this message because you have requested it from the Flyspray bugtracking system. If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.
THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.
A new Flyspray task has been opened. Details are below.
User who did this - Benjamin (bulkorok)
Attached to Project - sip-router
Summary - Maximum 70 else if statements
Task Type - Bug Report
Category - Core
Status - Unconfirmed
Assigned To -
Operating System - Linux
Severity - Low
Priority - Normal
Reported Version - 4.0
Due in Version - Undecided
Due Date - Undecided
Details - Hi,
after using 70 else if statements kamailio ignores following else if statements:
1: if (from_uri=~ "^sip:123@.+") { $var(cid) = "+12345"; } else
2-69: ...
70: if (from_uri=~ "^sip:321@.+") { $var(cid) = "+54321"; } else
71: if (from_uri=~ "^sip:111@.+") { $var(cid) = "+11111"; } else
71 is ignored.
If a new if else if block is created, it works again.
More information can be found at the following URL:
http://sip-router.org/tracker/index.php?do=details&task_id=403
You are receiving this message because you have requested it from the Flyspray bugtracking system. If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.
Module: sip-router
Branch: 4.1
Commit: 493e54de188f3ee03dd0c8a21ebcc4dd32e0c36e
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=493e54d…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Wed Feb 26 20:20:29 2014 +0100
parser/parse_addr_spec: comma allowd for start of tag value and mid tag value chars
(cherry picked from commit a9e900a3dd5c958f3188376c3c4d3179c68e2c32)
---
parser/parse_addr_spec.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/parser/parse_addr_spec.c b/parser/parse_addr_spec.c
index 9a8e3b3..80ad553 100644
--- a/parser/parse_addr_spec.c
+++ b/parser/parse_addr_spec.c
@@ -481,7 +481,8 @@ semicolon_add_param:
}
break;
} else {
- if(status==S_PARA_VALUE && param->type==TAG_PARAM) {
+ if((status==S_PARA_VALUE || status==PARA_VALUE_TOKEN)
+ && param->type==TAG_PARAM) {
/* if comma is not separator, allow it as part of value
* - some user agents use it */
break;
Module: sip-router
Branch: master
Commit: a9e900a3dd5c958f3188376c3c4d3179c68e2c32
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=a9e900a…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Wed Feb 26 20:20:29 2014 +0100
parser/parse_addr_spec: comma allowd for start of tag value and mid tag value chars
---
parser/parse_addr_spec.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/parser/parse_addr_spec.c b/parser/parse_addr_spec.c
index 9a8e3b3..80ad553 100644
--- a/parser/parse_addr_spec.c
+++ b/parser/parse_addr_spec.c
@@ -481,7 +481,8 @@ semicolon_add_param:
}
break;
} else {
- if(status==S_PARA_VALUE && param->type==TAG_PARAM) {
+ if((status==S_PARA_VALUE || status==PARA_VALUE_TOKEN)
+ && param->type==TAG_PARAM) {
/* if comma is not separator, allow it as part of value
* - some user agents use it */
break;
Module: sip-router
Branch: 4.1
Commit: f4b178ec5e348c7bd0a4c936a0d72a3702d80146
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=f4b178e…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Wed Feb 26 19:52:10 2014 +0100
parser/parse_addr_spec: allow comma in tag parameter
- some user agents uses it and it was in older versions
(cherry picked from commit 6156d2572e06fa661ef23face24c38203485d81a)
---
parser/parse_addr_spec.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/parser/parse_addr_spec.c b/parser/parse_addr_spec.c
index 179c907..9a8e3b3 100644
--- a/parser/parse_addr_spec.c
+++ b/parser/parse_addr_spec.c
@@ -480,9 +480,12 @@ semicolon_add_param:
goto error;
}
break;
- }
- else
- {
+ } else {
+ if(status==S_PARA_VALUE && param->type==TAG_PARAM) {
+ /* if comma is not separator, allow it as part of value
+ * - some user agents use it */
+ break;
+ }
LOG( L_ERR, "ERROR parse_to_param : "
"invalid character ',' in status %d: <<%.*s>>\n",
status, (int)(tmp-buffer), ZSW(buffer));
Module: sip-router
Branch: master
Commit: 6156d2572e06fa661ef23face24c38203485d81a
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=6156d25…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Wed Feb 26 19:52:10 2014 +0100
parser/parse_addr_spec: allow comma in tag parameter
- some user agents uses it and it was in older versions
---
parser/parse_addr_spec.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/parser/parse_addr_spec.c b/parser/parse_addr_spec.c
index 179c907..9a8e3b3 100644
--- a/parser/parse_addr_spec.c
+++ b/parser/parse_addr_spec.c
@@ -480,9 +480,12 @@ semicolon_add_param:
goto error;
}
break;
- }
- else
- {
+ } else {
+ if(status==S_PARA_VALUE && param->type==TAG_PARAM) {
+ /* if comma is not separator, allow it as part of value
+ * - some user agents use it */
+ break;
+ }
LOG( L_ERR, "ERROR parse_to_param : "
"invalid character ',' in status %d: <<%.*s>>\n",
status, (int)(tmp-buffer), ZSW(buffer));