[Pkg-voip-commits] [kamailio] 02/04: remove already applied upstream patches
Victor Seva
vseva at moszumanska.debian.org
Wed May 11 12:41:23 UTC 2016
This is an automated email from the git hooks/post-receive script.
vseva pushed a commit to branch master
in repository kamailio.
commit a835c6cc3690d3898534a492a4003de4973e2b98
Author: Victor Seva <vseva at debian.org>
Date: Wed May 11 14:18:42 2016 +0200
remove already applied upstream patches
---
debian/patches/series | 21 -
...-address-family-AF_PACKET-on-l-iface_name.patch | 29 -
...t-if-AF_PACKET-is-defined-at-compile-time.patch | 39 --
...pi-Fix-URL-to-library-home-page-in-README.patch | 102 ---
...if-ifa_addr-field-is-set-while-trying-to-.patch | 29 -
...n-check-for-ifa-ifa_addr-in-add_intefaces.patch | 34 -
...6-Makefile.defs-re-enable-mem-join-define.patch | 28 -
...dialog-fix-dlg-from_bindaddr-name-parsing.patch | 26 -
.../0038-dialog-fix-dlg-from_bindaddr-getter.patch | 25 -
...register-server-process-with-the-local-na.patch | 78 ---
...x-compile-warning-unused-but-set-variable.patch | 36 --
...x-use-UNIVERSAL-is-a-fatal-error-since-pe.patch | 71 ---
..._client-Clarify-DNS-resolver-use-for-CURL.patch | 50 --
...0043-dialog-Document-shortest-ka_interval.patch | 42 --
...te-README-with-explanation-of-in-dialog-r.patch | 49 --
...-erlang-fix-uninitialized-member-variable.patch | 27 -
...046-erlang-fix-memory-leak-in-debug-macro.patch | 27 -
.../0047-erlang-fix-parsing-function-params.patch | 708 ---------------------
...ed-use-of-obsolete-function-json_object_o.patch | 55 --
...eplaced-use-of-obsolete-function-json_obj.patch | 92 ---
...ove-ending-parenthesis-in-ifdef-condition.patch | 32 -
...fs-detect-kfreebsd-OS-and-set-its-default.patch | 83 ---
22 files changed, 1683 deletions(-)
diff --git a/debian/patches/series b/debian/patches/series
index bfa4b10..9de40e1 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,24 +1,3 @@
-upstream/0001-core-skip-address-family-AF_PACKET-on-l-iface_name.patch
-upstream/0002-core-test-if-AF_PACKET-is-defined-at-compile-time.patch
-upstream/0033-evapi-Fix-URL-to-library-home-page-in-README.patch
-upstream/0034-core-check-if-ifa_addr-field-is-set-while-trying-to-.patch
-upstream/0035-core-common-check-for-ifa-ifa_addr-in-add_intefaces.patch
-upstream/0036-Makefile.defs-re-enable-mem-join-define.patch
-upstream/0037-dialog-fix-dlg-from_bindaddr-name-parsing.patch
-upstream/0038-dialog-fix-dlg-from_bindaddr-getter.patch
-upstream/0039-erlang-fix-register-server-process-with-the-local-na.patch
-upstream/0040-erlang-fix-compile-warning-unused-but-set-variable.patch
-upstream/0041-app_perl-Fix-use-UNIVERSAL-is-a-fatal-error-since-pe.patch
-upstream/0042-http_client-Clarify-DNS-resolver-use-for-CURL.patch
-upstream/0043-dialog-Document-shortest-ka_interval.patch
-upstream/0044-dialog-Update-README-with-explanation-of-in-dialog-r.patch
-upstream/0045-erlang-fix-uninitialized-member-variable.patch
-upstream/0046-erlang-fix-memory-leak-in-debug-macro.patch
-upstream/0047-erlang-fix-parsing-function-params.patch
-upstream/0048-json-replaced-use-of-obsolete-function-json_object_o.patch
-upstream/0049-jsonrpc-c-replaced-use-of-obsolete-function-json_obj.patch
-upstream/0050-core-remove-ending-parenthesis-in-ifdef-condition.patch
-upstream/0051-Makefile.defs-detect-kfreebsd-OS-and-set-its-default.patch
no_lib64_on_64_bits.patch
no_INSTALL_file.patch
fix_export.patch
diff --git a/debian/patches/upstream/0001-core-skip-address-family-AF_PACKET-on-l-iface_name.patch b/debian/patches/upstream/0001-core-skip-address-family-AF_PACKET-on-l-iface_name.patch
deleted file mode 100644
index edea666..0000000
--- a/debian/patches/upstream/0001-core-skip-address-family-AF_PACKET-on-l-iface_name.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 4992dfbb9f15cfb8ade99be4e6d3087146cb8e22 Mon Sep 17 00:00:00 2001
-From: schoberw <walter.schober at neotel.at>
-Date: Fri, 1 Apr 2016 10:34:11 +0200
-Subject: [PATCH] core: skip address family AF_PACKET on -l iface_name
-
-- socket_info.c: getifaddrs() returns AF_PACKET, AF_INET and AF_INET6 addressed of an interface.
- AF_PACKET are of no use and breaks startup with an -l eth0:5060 cmd line param
-(cherry picked from commit d7fca53e8c5409849ec044098a143e7254129c00)
----
- socket_info.c | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/socket_info.c b/socket_info.c
-index d06fdcf..1d28977 100644
---- a/socket_info.c
-+++ b/socket_info.c
-@@ -1205,6 +1205,9 @@ int add_interfaces(char* if_name, int family, unsigned short port,
-
- for (ifa = ifap; ifa; ifa = ifa->ifa_next)
- {
-+ /* skip AF_PACKET addr family since it is of no use later on */
-+ if (ifa->ifa_addr->sa_family == AF_PACKET)
-+ continue;
- if (if_name && strcmp(if_name, ifa->ifa_name))
- continue;
- if (family && family != ifa->ifa_addr->sa_family)
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0002-core-test-if-AF_PACKET-is-defined-at-compile-time.patch b/debian/patches/upstream/0002-core-test-if-AF_PACKET-is-defined-at-compile-time.patch
deleted file mode 100644
index 1d295b4..0000000
--- a/debian/patches/upstream/0002-core-test-if-AF_PACKET-is-defined-at-compile-time.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From e6dd2c172be3712e8c468cbe7e55ba94d81a7b62 Mon Sep 17 00:00:00 2001
-From: Daniel-Constantin Mierla <miconda at gmail.com>
-Date: Fri, 1 Apr 2016 11:10:46 +0200
-Subject: [PATCH] core: test if AF_PACKET is defined at compile time
-
-- mac os x (and perhaps *BSDs) doesn't have it
-
-(cherry picked from commit 8543993e1f702aef80887c0e72b9bf67c62c1617)
----
- socket_info.c | 4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-diff --git a/socket_info.c b/socket_info.c
-index 1d28977..cecfef9 100644
---- a/socket_info.c
-+++ b/socket_info.c
-@@ -1205,16 +1205,18 @@ int add_interfaces(char* if_name, int family, unsigned short port,
-
- for (ifa = ifap; ifa; ifa = ifa->ifa_next)
- {
-+#ifdef AF_PACKET
- /* skip AF_PACKET addr family since it is of no use later on */
- if (ifa->ifa_addr->sa_family == AF_PACKET)
- continue;
-+#endif
- if (if_name && strcmp(if_name, ifa->ifa_name))
- continue;
- if (family && family != ifa->ifa_addr->sa_family)
- continue;
- sockaddr2ip_addr(&addr, (struct sockaddr*)ifa->ifa_addr);
- tmp=ip_addr2a(&addr);
-- if (ifa->ifa_flags & IFF_LOOPBACK)
-+ if (ifa->ifa_flags & IFF_LOOPBACK)
- flags = SI_IS_LO;
- else
- flags = SI_NONE;
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0033-evapi-Fix-URL-to-library-home-page-in-README.patch b/debian/patches/upstream/0033-evapi-Fix-URL-to-library-home-page-in-README.patch
deleted file mode 100644
index e49a775..0000000
--- a/debian/patches/upstream/0033-evapi-Fix-URL-to-library-home-page-in-README.patch
+++ /dev/null
@@ -1,102 +0,0 @@
-From 87af066010ca0b89a4752fe593c091253b842d6c Mon Sep 17 00:00:00 2001
-From: "Olle E. Johansson" <oej at edvina.net>
-Date: Sun, 3 Apr 2016 21:45:37 +0200
-Subject: [PATCH] evapi Fix URL to library home page in README
-
----
- modules/evapi/README | 16 ++++++++--------
- modules/evapi/doc/evapi_admin.xml | 2 +-
- 2 files changed, 9 insertions(+), 9 deletions(-)
-
-diff --git a/modules/evapi/README b/modules/evapi/README
-index a8465ce..59fe136 100644
---- a/modules/evapi/README
-+++ b/modules/evapi/README
-@@ -10,7 +10,7 @@ Daniel-Constantin Mierla
-
- <miconda at gmail.com>
-
-- Copyright © 2014 asipto.com
-+ Copyright � 2014 asipto.com
- __________________________________________________________________
-
- Table of Contents
-@@ -109,7 +109,7 @@ Chapter 1. Admin Guide
-
- The following libraries or applications must be installed before
- running Kamailio with this module loaded:
-- * libev - http://software.schmorp.de/pkg/libev
-+ * libev - http://software.schmorp.de/pkg/libev.html
-
- 3. Parameters
-
-@@ -158,7 +158,7 @@ modparam("evapi", "netstring_format", 0)
- 4.2. evapi_async_relay(evdata)
- 4.3. evapi_close()
-
--4.1. evapi_relay(evdata)
-+4.1. evapi_relay(evdata)
-
- Relay the event data given as parameter to connected applications.
-
-@@ -188,7 +188,7 @@ evapi_relay("{ \"event\": \"test\",\n \"data\": { \"fU\": \"$fU\" }\n}");
- },
- ...
-
--4.2. evapi_async_relay(evdata)
-+4.2. evapi_async_relay(evdata)
-
- Relay the event data given as parameter to connected applications.
- Before evaluating the parameter, the request processing is suspended
-@@ -210,7 +210,7 @@ evapi_async_relay("{ \"event\": \"suspend\",\n \"data\":"
- " { \"index\": \"$T(id_index)\", \"label\": \"$T(id_label)\" }\n}");
- ...
-
--4.3. evapi_close()
-+4.3. evapi_close()
-
- Close evapi current client connection.
-
-@@ -232,7 +232,7 @@ event_route[evapi:connection-new] {
- 5.2. evapi:connection-closed
- 5.3. evapi:message-received
-
--5.1. evapi:connection-new
-+5.1. evapi:connection-new
-
- If defined, the module calls event_route[evapi:connection-new] when a
- new client is connected.
-@@ -242,7 +242,7 @@ event_route[evapi:connection-new] {
- }
- ...
-
--5.2. evapi:connection-closed
-+5.2. evapi:connection-closed
-
- If defined, the module calls event_route[evapi:connection-closed] when
- a client connection is closed.
-@@ -252,7 +252,7 @@ event_route[evapi:connection-closed] {
- }
- ...
-
--5.3. evapi:message-received
-+5.3. evapi:message-received
-
- If defined, the module calls event_route[evapi:message-received] when a
- message is received from a client.
-diff --git a/modules/evapi/doc/evapi_admin.xml b/modules/evapi/doc/evapi_admin.xml
-index 574adef..30fa61d 100644
---- a/modules/evapi/doc/evapi_admin.xml
-+++ b/modules/evapi/doc/evapi_admin.xml
-@@ -54,7 +54,7 @@
- <itemizedlist>
- <listitem>
- <para>
-- <emphasis>libev</emphasis> - <ulink url="http://software.schmorp.de/pkg/libev">http://software.schmorp.de/pkg/libev</ulink>
-+ <emphasis>libev</emphasis> - <ulink url="http://software.schmorp.de/pkg/libev.html">http://software.schmorp.de/pkg/libev.html</ulink>
- </para>
- </listitem>
- </itemizedlist>
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0034-core-check-if-ifa_addr-field-is-set-while-trying-to-.patch b/debian/patches/upstream/0034-core-check-if-ifa_addr-field-is-set-while-trying-to-.patch
deleted file mode 100644
index cd10e17..0000000
--- a/debian/patches/upstream/0034-core-check-if-ifa_addr-field-is-set-while-trying-to-.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 6684be6b4c405ab24dd6a5a19267ceef6aa95503 Mon Sep 17 00:00:00 2001
-From: Daniel-Constantin Mierla <miconda at gmail.com>
-Date: Wed, 6 Apr 2016 18:55:57 +0200
-Subject: [PATCH] core: check if ifa_addr field is set while trying to skip
- AF_PACKET interfaces
-
-- reported by Juha Heinanen
-
-(cherry picked from commit 1545b8de396e8e5d0ef24c9102beff18b3cf36e5)
----
- socket_info.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/socket_info.c b/socket_info.c
-index cecfef9..95c6ee6 100644
---- a/socket_info.c
-+++ b/socket_info.c
-@@ -1207,7 +1207,7 @@ int add_interfaces(char* if_name, int family, unsigned short port,
- {
- #ifdef AF_PACKET
- /* skip AF_PACKET addr family since it is of no use later on */
-- if (ifa->ifa_addr->sa_family == AF_PACKET)
-+ if (ifa->ifa_addr && ifa->ifa_addr->sa_family == AF_PACKET)
- continue;
- #endif
- if (if_name && strcmp(if_name, ifa->ifa_name))
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0035-core-common-check-for-ifa-ifa_addr-in-add_intefaces.patch b/debian/patches/upstream/0035-core-common-check-for-ifa-ifa_addr-in-add_intefaces.patch
deleted file mode 100644
index 2ca965f..0000000
--- a/debian/patches/upstream/0035-core-common-check-for-ifa-ifa_addr-in-add_intefaces.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 49ec5fa5d9bb939b80ef3994b5f0c04e7525ab9f Mon Sep 17 00:00:00 2001
-From: Daniel-Constantin Mierla <miconda at gmail.com>
-Date: Wed, 6 Apr 2016 19:22:58 +0200
-Subject: [PATCH] core: common check for ifa->ifa_addr in add_intefaces
-
-- if no ip address associated with the network interface, it is not
- useful anyhow
-
-(cherry picked from commit c395ae00d7970be0a857265e9324a50bcb00f4d0)
----
- socket_info.c | 5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/socket_info.c b/socket_info.c
-index 95c6ee6..aa8928a 100644
---- a/socket_info.c
-+++ b/socket_info.c
-@@ -1205,9 +1205,12 @@ int add_interfaces(char* if_name, int family, unsigned short port,
-
- for (ifa = ifap; ifa; ifa = ifa->ifa_next)
- {
-+ /* skip if no IP addr associated with the interface */
-+ if (ifa->ifa_addr==0)
-+ continue;
- #ifdef AF_PACKET
- /* skip AF_PACKET addr family since it is of no use later on */
-- if (ifa->ifa_addr && ifa->ifa_addr->sa_family == AF_PACKET)
-+ if (ifa->ifa_addr->sa_family == AF_PACKET)
- continue;
- #endif
- if (if_name && strcmp(if_name, ifa->ifa_name))
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0036-Makefile.defs-re-enable-mem-join-define.patch b/debian/patches/upstream/0036-Makefile.defs-re-enable-mem-join-define.patch
deleted file mode 100644
index 5edd165..0000000
--- a/debian/patches/upstream/0036-Makefile.defs-re-enable-mem-join-define.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From b21b9cd9cb6a08b9bfc9d025b4e6a64a12e50d65 Mon Sep 17 00:00:00 2001
-From: Daniel-Constantin Mierla <miconda at gmail.com>
-Date: Fri, 8 Apr 2016 15:10:55 +0200
-Subject: [PATCH] Makefile.defs: re-enable mem join define
-
-- lost when introduced the option to select the memory manager by
- command line parameter -x
-
-(cherry picked from commit 33c6aafcd46269ce283908f49fbf70b9d73624b1)
----
- Makefile.defs | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/Makefile.defs b/Makefile.defs
-index 26205e8..245f9b4 100644
---- a/Makefile.defs
-+++ b/Makefile.defs
-@@ -664,6 +664,7 @@ C_DEFS= $(extra_defs) \
- # debugging symbols in all cases (-g). --andrei
-
- # memory managers and related debug mode
-+C_DEFS+= -DMEM_JOIN_FREE
- # enable f_malloc
- C_DEFS+= -DF_MALLOC
- # enable q_malloc
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0037-dialog-fix-dlg-from_bindaddr-name-parsing.patch b/debian/patches/upstream/0037-dialog-fix-dlg-from_bindaddr-name-parsing.patch
deleted file mode 100644
index a4376de..0000000
--- a/debian/patches/upstream/0037-dialog-fix-dlg-from_bindaddr-name-parsing.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From 1ec385ccd9054952b86cc976ae1debe70dc8d297 Mon Sep 17 00:00:00 2001
-From: Camille Oudot <camille.oudot at orange.com>
-Date: Mon, 11 Apr 2016 17:02:03 +0200
-Subject: [PATCH] dialog: fix $dlg(from_bindaddr) name parsing
-
-(cherry picked from commit f95789fd39fcce7b3aa3a0ab8665664afd8bc196)
----
- modules/dialog/dlg_var.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/modules/dialog/dlg_var.c b/modules/dialog/dlg_var.c
-index e8c84ed..450f8a5 100644
---- a/modules/dialog/dlg_var.c
-+++ b/modules/dialog/dlg_var.c
-@@ -877,7 +877,7 @@ int pv_parse_dlg_name(pv_spec_p sp, str *in)
- else goto error;
- break;
- case 13:
-- if(strncmp(in->s, "from_bindaddr", 20)==0)
-+ if(strncmp(in->s, "from_bindaddr", 13)==0)
- sp->pvp.pvn.u.isname.name.n = 2;
- else goto error;
- break;
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0038-dialog-fix-dlg-from_bindaddr-getter.patch b/debian/patches/upstream/0038-dialog-fix-dlg-from_bindaddr-getter.patch
deleted file mode 100644
index 56ae84d..0000000
--- a/debian/patches/upstream/0038-dialog-fix-dlg-from_bindaddr-getter.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 02b17b881d63fe91221f5673dd3418831c943bd0 Mon Sep 17 00:00:00 2001
-From: Camille Oudot <camille.oudot at orange.com>
-Date: Mon, 11 Apr 2016 18:53:05 +0200
-Subject: [PATCH] dialog: fix $dlg(from_bindaddr) getter
-
----
- modules/dialog/dlg_var.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/modules/dialog/dlg_var.c b/modules/dialog/dlg_var.c
-index 450f8a5..8d76b8f 100644
---- a/modules/dialog/dlg_var.c
-+++ b/modules/dialog/dlg_var.c
-@@ -878,7 +878,7 @@ int pv_parse_dlg_name(pv_spec_p sp, str *in)
- break;
- case 13:
- if(strncmp(in->s, "from_bindaddr", 13)==0)
-- sp->pvp.pvn.u.isname.name.n = 2;
-+ sp->pvp.pvn.u.isname.name.n = 20;
- else goto error;
- break;
- default:
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0039-erlang-fix-register-server-process-with-the-local-na.patch b/debian/patches/upstream/0039-erlang-fix-register-server-process-with-the-local-na.patch
deleted file mode 100644
index 6afa2b9..0000000
--- a/debian/patches/upstream/0039-erlang-fix-register-server-process-with-the-local-na.patch
+++ /dev/null
@@ -1,78 +0,0 @@
-From 297d9732504290a1209ae7cf883127fadc1156aa Mon Sep 17 00:00:00 2001
-From: Seudin Kasumovic <seudin.kasumovic at gmail.com>
-Date: Wed, 13 Apr 2016 00:15:56 +0200
-Subject: [PATCH] erlang: fix register server process with the local name
- server epmd
-
-- use correct alive name when number of C nodes greater then 1
-- fix error check on register server process
-
-(cherry picked from commit 6f268b5a9d0bd07e689c401cb7221bb0f2c5f8be)
----
- modules/erlang/cnode.c | 2 +-
- modules/erlang/epmd.c | 4 ++--
- modules/erlang/epmd.h | 2 +-
- modules/erlang/erl_helpers.c | 4 ++--
- 4 files changed, 6 insertions(+), 6 deletions(-)
-
-diff --git a/modules/erlang/cnode.c b/modules/erlang/cnode.c
-index f0f6e03..1e9b5d6 100644
---- a/modules/erlang/cnode.c
-+++ b/modules/erlang/cnode.c
-@@ -226,7 +226,7 @@ int init_cnode_sockets(int cnode_id)
- io_handler_ins(phandler);
-
- /* start epmd handler - publish Kamailo C node */
-- if (epmd_init((epmd_handler_t*)phandler) < 0 ) {
-+ if (epmd_init((epmd_handler_t*)phandler, &alivename) < 0 ) {
- return -1;
- }
-
-diff --git a/modules/erlang/epmd.c b/modules/erlang/epmd.c
-index 3a47e0f..43889aa 100644
---- a/modules/erlang/epmd.c
-+++ b/modules/erlang/epmd.c
-@@ -39,9 +39,9 @@
- /**
- * \brief Initialize EPMD handler
- */
--int epmd_init(epmd_handler_t *epmd)
-+int epmd_init(epmd_handler_t *epmd, str *alivename)
- {
-- epmd->sockfd = erl_init_node(&epmd->ec, &cnode_alivename, &cnode_host, &cookie);
-+ epmd->sockfd = erl_init_node(&epmd->ec, alivename, &cnode_host, &cookie);
- epmd->handle_f = handle_epmd;
- epmd->wait_tmo_f = NULL;
- epmd->destroy_f = NULL;
-diff --git a/modules/erlang/epmd.h b/modules/erlang/epmd.h
-index d5d4507..09b3eb5 100644
---- a/modules/erlang/epmd.h
-+++ b/modules/erlang/epmd.h
-@@ -55,7 +55,7 @@ typedef struct epmd_handler_s
-
- } epmd_handler_t;
-
--int epmd_init(epmd_handler_t *epmd);
-+int epmd_init(epmd_handler_t *epmd, str *alivename);
- int handle_epmd(handler_common_t *phandler);
-
- #endif /* EPMD_H_ */
-diff --git a/modules/erlang/erl_helpers.c b/modules/erlang/erl_helpers.c
-index cc43e92..f702a8b 100644
---- a/modules/erlang/erl_helpers.c
-+++ b/modules/erlang/erl_helpers.c
-@@ -307,9 +307,9 @@ int erl_init_node(ei_cnode *ec, const str *alivename, const str *hostname, const
- sockaddr2ip_addr(&ip, addr);
-
- /* publish */
-- if ((epmdfd = ei_publish_tmo(ec, port, timeout_ms)) == -1) {
-+ if ((epmdfd = ei_publish_tmo(ec, port, timeout_ms)) < 0) {
-
-- LM_ERR("Failed to publish port %u to epmd, check is epmd started\n", port);
-+ LM_DBG("Failed publish %s:%u[%u] as %s: %s (%d)\n",ip_addr2strz(&ip),port,listen_fd,nodename, strerror(erl_errno), epmdfd);
-
- erl_close_socket(listen_fd);
- return -1;
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0040-erlang-fix-compile-warning-unused-but-set-variable.patch b/debian/patches/upstream/0040-erlang-fix-compile-warning-unused-but-set-variable.patch
deleted file mode 100644
index a5cf975..0000000
--- a/debian/patches/upstream/0040-erlang-fix-compile-warning-unused-but-set-variable.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From 3e29e0bcfb14f0e95639eb99b777da84d46becf1 Mon Sep 17 00:00:00 2001
-From: Seudin Kasumovic <seudin.kasumovic at gmail.com>
-Date: Wed, 13 Apr 2016 00:34:41 +0200
-Subject: [PATCH] erlang: fix compile warning unused but set variable
-
-- get rid of this variable
-
-(cherry picked from commit 32c3435c8122903958834002ba843b93c49495f0)
----
- modules/erlang/erl_helpers.c | 3 ---
- 1 file changed, 3 deletions(-)
-
-diff --git a/modules/erlang/erl_helpers.c b/modules/erlang/erl_helpers.c
-index f702a8b..1ec21d1 100644
---- a/modules/erlang/erl_helpers.c
-+++ b/modules/erlang/erl_helpers.c
-@@ -235,7 +235,6 @@ int erl_init_ec(ei_cnode *ec, const str *alivename, const str *hostname, const s
- char nodename[MAXNODELEN];
-
- int result;
-- int port;
-
- /* copy the nodename into something we can modify */
- if (snprintf(nodename, MAXNODELEN, "%.*s@%.*s", STR_FMT(alivename), STR_FMT(hostname)) >= MAXNODELEN) {
-@@ -256,8 +255,6 @@ int erl_init_ec(ei_cnode *ec, const str *alivename, const str *hostname, const s
- return -1;
- }
-
-- port = sockaddr_port(addr);
--
- LM_DBG("initialized ec for cnode '%s' on %.*s[%s] creation %d.\n", nodename, STR_FMT(hostname), ip_addr2strz(&ip), creation);
-
- freeaddrinfo(ai);
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0041-app_perl-Fix-use-UNIVERSAL-is-a-fatal-error-since-pe.patch b/debian/patches/upstream/0041-app_perl-Fix-use-UNIVERSAL-is-a-fatal-error-since-pe.patch
deleted file mode 100644
index 97b81f5..0000000
--- a/debian/patches/upstream/0041-app_perl-Fix-use-UNIVERSAL-is-a-fatal-error-since-pe.patch
+++ /dev/null
@@ -1,71 +0,0 @@
-From 3356d6aca4c85e7c086b1d46cf06e56635fd4739 Mon Sep 17 00:00:00 2001
-From: Victor Seva <linuxmaniac at torreviejawireless.org>
-Date: Fri, 15 Apr 2016 09:09:08 +0200
-Subject: [PATCH] app_perl: Fix "use UNIVERSAL" is a fatal error since perl
- 5.22
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-* Author: Julián Moreno Patiño <julian at debian.org>
-* Fix #516
-* from: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=821039
-
-(cherry picked from commit b77ed54d33f171d170ca89252f0a31a0d23996fa)
----
- modules/app_perl/lib/perl/Kamailio/LDAPUtils/LDAPConnection.pm | 3 +--
- modules/app_perl/lib/perl/Kamailio/VDB.pm | 7 +++----
- 2 files changed, 4 insertions(+), 6 deletions(-)
-
-diff --git a/modules/app_perl/lib/perl/Kamailio/LDAPUtils/LDAPConnection.pm b/modules/app_perl/lib/perl/Kamailio/LDAPUtils/LDAPConnection.pm
-index f97a22d..3b6509a 100644
---- a/modules/app_perl/lib/perl/Kamailio/LDAPUtils/LDAPConnection.pm
-+++ b/modules/app_perl/lib/perl/Kamailio/LDAPUtils/LDAPConnection.pm
-@@ -52,7 +52,6 @@ package Kamailio::LDAPUtils::LDAPConnection;
- use Kamailio::LDAPUtils::LDAPConf;
- use Net::LDAP;
- use Authen::SASL;
--use UNIVERSAL qw( isa );
-
- my $ldap_singleton = undef;
-
-@@ -185,7 +184,7 @@ sub search {
-
- my $ldap = undef;
-
-- if( isa($conf ,"Kamailio::LDAPUtils::LDAPConnection") ) {
-+ if( $conf->isa("Kamailio::LDAPUtils::LDAPConnection") ) {
- $ldap = $conf;
- } else {
- if( ! $ldap_singleton ) {
-diff --git a/modules/app_perl/lib/perl/Kamailio/VDB.pm b/modules/app_perl/lib/perl/Kamailio/VDB.pm
-index 8c6bdb3..0fff716 100644
---- a/modules/app_perl/lib/perl/Kamailio/VDB.pm
-+++ b/modules/app_perl/lib/perl/Kamailio/VDB.pm
-@@ -45,7 +45,6 @@ use Kamailio::VDB::Result;
- use Kamailio::VDB::Value;
- use Kamailio::VDB::VTab;
-
--use UNIVERSAL qw ( can );
-
- our @ISA = qw ( Kamailio::Utils::Debug );
-
-@@ -87,12 +86,12 @@ sub use_table {
-
- Kamailio::log(L_DBG, "perlvdb:VDB: Setting VTab: v is $v (pkg is $pkg, func/method is $3)\n");
-
-- if (can($pkg, $3)) {
-+ if ($pkg->can($3)) {
- $self->{vtabs}->{$v} = new Kamailio::VDB::VTab( func => $pkg . "::" . $3);
-- } elsif (can($v, "init")) {
-+ } elsif ($v->can("init")) {
- $v->init();
- $self->{vtabs}->{$v} = new Kamailio::VDB::VTab( obj => $v );
-- } elsif (can($v, "new")) {
-+ } elsif ($v->can("new")) {
- my $obj = $v->new();
- $self->{vtabs}->{$v} = new Kamailio::VDB::VTab( obj => $obj );
- } else {
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0042-http_client-Clarify-DNS-resolver-use-for-CURL.patch b/debian/patches/upstream/0042-http_client-Clarify-DNS-resolver-use-for-CURL.patch
deleted file mode 100644
index d84d0f7..0000000
--- a/debian/patches/upstream/0042-http_client-Clarify-DNS-resolver-use-for-CURL.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From 22003d5cba54b5c0d0f0af06f62be24190bef231 Mon Sep 17 00:00:00 2001
-From: "Olle E. Johansson" <oej at edvina.net>
-Date: Mon, 18 Apr 2016 13:43:15 +0200
-Subject: [PATCH] http_client Clarify DNS resolver use for CURL
-
-(cherry picked from commit e85706b549e691404e3caf401fa4cf86c5ab90de)
----
- modules/http_client/README | 6 ++++++
- modules/http_client/doc/http_client_admin.xml | 8 ++++++++
- 2 files changed, 14 insertions(+)
-
-diff --git a/modules/http_client/README b/modules/http_client/README
-index 45449ef..5d503e9 100644
---- a/modules/http_client/README
-+++ b/modules/http_client/README
-@@ -171,6 +171,12 @@ Chapter 1. Admin Guide
- and get access to parts of the reply. This function has been ported
- from the utils module and now use the same libcurl functions.
-
-+ The http_client module use the CURL library setting up connections. The
-+ CURL library by default use the system configured DNS resolvers, not
-+ the Kamailio resolver.
-+
-+ The module is limited to using HTTP and HTTPS protocols.
-+
- 2. Dependencies
-
- 2.1. Kamailio Modules
-diff --git a/modules/http_client/doc/http_client_admin.xml b/modules/http_client/doc/http_client_admin.xml
-index 07b2d02..e2c32f5 100644
---- a/modules/http_client/doc/http_client_admin.xml
-+++ b/modules/http_client/doc/http_client_admin.xml
-@@ -43,6 +43,14 @@
- been ported from the utils module and now use the same libcurl
- functions.
- </para>
-+ <para>
-+ The http_client module use the CURL library setting up connections.
-+ The CURL library by default use the system configured DNS resolvers,
-+ not the Kamailio resolver.
-+ </para>
-+ <para>
-+ The module is limited to using HTTP and HTTPS protocols.
-+ </para>
- </section>
- <section>
- <title>Dependencies</title>
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0043-dialog-Document-shortest-ka_interval.patch b/debian/patches/upstream/0043-dialog-Document-shortest-ka_interval.patch
deleted file mode 100644
index 3090382..0000000
--- a/debian/patches/upstream/0043-dialog-Document-shortest-ka_interval.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 19d4d3f5a1a49335377c9befd238b729b957f42b Mon Sep 17 00:00:00 2001
-From: "Olle E. Johansson" <oej at edvina.net>
-Date: Tue, 19 Apr 2016 14:11:33 +0200
-Subject: [PATCH] dialog Document shortest ka_interval
-
-(cherry picked from commit 9710f1c92baee8ec379d64b75531bed5cf7695fb)
----
- modules/dialog/README | 3 ++-
- modules/dialog/doc/dialog_admin.xml | 3 ++-
- 2 files changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/modules/dialog/README b/modules/dialog/README
-index 1774a7f..83206bc 100644
---- a/modules/dialog/README
-+++ b/modules/dialog/README
-@@ -1147,7 +1147,8 @@ modparam("dialog", "ka_timer", 10)
- dialog setup or previous keep-alive. The value represents the number of
- seconds.
-
-- Default value is "0" (no keep alive).
-+ Default value is "0" (no keep alive). The lowest settable interval is
-+ 30 seconds.
-
- Example 1.49. Set ka_interval parameter
- ...
-diff --git a/modules/dialog/doc/dialog_admin.xml b/modules/dialog/doc/dialog_admin.xml
-index 50dffa7..b02826a 100644
---- a/modules/dialog/doc/dialog_admin.xml
-+++ b/modules/dialog/doc/dialog_admin.xml
-@@ -1249,7 +1249,8 @@ modparam("dialog", "ka_timer", 10)
- </para>
- <para>
- <emphasis>
-- Default value is <quote>0</quote> (no keep alive).
-+ Default value is <quote>0</quote> (no keep alive). The lowest
-+ settable interval is 30 seconds.
- </emphasis>
- </para>
- <example>
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0044-dialog-Update-README-with-explanation-of-in-dialog-r.patch b/debian/patches/upstream/0044-dialog-Update-README-with-explanation-of-in-dialog-r.patch
deleted file mode 100644
index aaa1a99..0000000
--- a/debian/patches/upstream/0044-dialog-Update-README-with-explanation-of-in-dialog-r.patch
+++ /dev/null
@@ -1,49 +0,0 @@
-From c302b9e920342869721342c42f9014bd079fb456 Mon Sep 17 00:00:00 2001
-From: "Olle E. Johansson" <oej at edvina.net>
-Date: Tue, 19 Apr 2016 21:24:31 +0200
-Subject: [PATCH] dialog Update README with explanation of in-dialog request
- behaviour
-
-(cherry picked from commit 19ef4f6ec8c22848eb4386f5f4996d5091c65688)
----
- modules/dialog/README | 5 +++++
- modules/dialog/doc/dialog_admin.xml | 7 +++++++
- 2 files changed, 12 insertions(+)
-
-diff --git a/modules/dialog/README b/modules/dialog/README
-index 83206bc..97c2602 100644
---- a/modules/dialog/README
-+++ b/modules/dialog/README
-@@ -1147,6 +1147,11 @@ modparam("dialog", "ka_timer", 10)
- dialog setup or previous keep-alive. The value represents the number of
- seconds.
-
-+ If the requests times out (generating a 408) or if the UA responds with
-+ 481 the lifetime is set to 10 seconds. When lifetime expires the dialog
-+ will be terminated. Any other response (including error responses) will
-+ reset the timers.
-+
- Default value is "0" (no keep alive). The lowest settable interval is
- 30 seconds.
-
-diff --git a/modules/dialog/doc/dialog_admin.xml b/modules/dialog/doc/dialog_admin.xml
-index b02826a..3fff0fe 100644
---- a/modules/dialog/doc/dialog_admin.xml
-+++ b/modules/dialog/doc/dialog_admin.xml
-@@ -1248,6 +1248,13 @@ modparam("dialog", "ka_timer", 10)
- The value represents the number of seconds.
- </para>
- <para>
-+ If the requests times out (generating a 408) or if the
-+ UA responds with 481 the lifetime is set to 10 seconds.
-+ When lifetime expires the dialog will be terminated.
-+ Any other response (including error responses) will
-+ reset the timers.
-+ </para>
-+ <para>
- <emphasis>
- Default value is <quote>0</quote> (no keep alive). The lowest
- settable interval is 30 seconds.
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0045-erlang-fix-uninitialized-member-variable.patch b/debian/patches/upstream/0045-erlang-fix-uninitialized-member-variable.patch
deleted file mode 100644
index 9bd9b46..0000000
--- a/debian/patches/upstream/0045-erlang-fix-uninitialized-member-variable.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 8d07ef72e8280b4367e430bf081d54e0a0b5f4c1 Mon Sep 17 00:00:00 2001
-From: Seudin Kasumovic <seudin.kasumovic at gmail.com>
-Date: Mon, 18 Apr 2016 11:30:23 +0200
-Subject: [PATCH] erlang: fix uninitialized member variable
-
-- avoid conditional jump on uninitialized value
-
-(cherry picked from commit 0e3b19f4b99ea0b9e4eff2decb641e5da2488573)
----
- modules/erlang/worker.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/modules/erlang/worker.c b/modules/erlang/worker.c
-index 0bf1be8..86ad3f9 100644
---- a/modules/erlang/worker.c
-+++ b/modules/erlang/worker.c
-@@ -44,6 +44,7 @@ int worker_init(worker_handler_t *phandler, int fd, const ei_cnode *ec)
- phandler->sockfd = fd;
- phandler->ec = *ec;
- phandler->next = NULL;
-+ phandler->new = NULL;
-
- return 0;
- }
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0046-erlang-fix-memory-leak-in-debug-macro.patch b/debian/patches/upstream/0046-erlang-fix-memory-leak-in-debug-macro.patch
deleted file mode 100644
index 55c6136..0000000
--- a/debian/patches/upstream/0046-erlang-fix-memory-leak-in-debug-macro.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 2c650622cf7cd37dc1c5177ad314681113ac324d Mon Sep 17 00:00:00 2001
-From: Seudin Kasumovic <seudin.kasumovic at gmail.com>
-Date: Wed, 20 Apr 2016 11:10:39 +0200
-Subject: [PATCH] erlang: fix memory leak in debug macro
-
-- free temporary used encoding buffer
-
-(cherry picked from commit 2b11990929ae1d097bfb66848136bd247130263b)
----
- modules/erlang/erl_helpers.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/modules/erlang/erl_helpers.h b/modules/erlang/erl_helpers.h
-index 2aed063..fa8fdc5 100644
---- a/modules/erlang/erl_helpers.h
-+++ b/modules/erlang/erl_helpers.h
-@@ -141,6 +141,7 @@ do { \
- ei_s_print_term(&pbuf, pidbuf.buff, &i); \
- ei_x_print_reg_msg(buf, pbuf, send); \
- free(pbuf); \
-+ ei_x_free(&pidbuf); \
- } while(0)
-
- int ei_decode_strorbin(char *buf, int *index, int maxlen, char *dst);
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0047-erlang-fix-parsing-function-params.patch b/debian/patches/upstream/0047-erlang-fix-parsing-function-params.patch
deleted file mode 100644
index 847914c..0000000
--- a/debian/patches/upstream/0047-erlang-fix-parsing-function-params.patch
+++ /dev/null
@@ -1,708 +0,0 @@
-From bf76f94e939c0d96ca25a2d75623e7fcff78c01e Mon Sep 17 00:00:00 2001
-From: Seudin Kasumovic <seudin.kasumovic at gmail.com>
-Date: Wed, 20 Apr 2016 11:36:40 +0200
-Subject: [PATCH] erlang: fix parsing function params
-
-- remove double parsing function params
-- free memory used in parsing params
-
-(cherry picked from commit 28b320088fcad8b8875f0528873a49cba9c74619)
----
- modules/erlang/mod_erlang.c | 310 +++++++++++++++++++++++++-------------------
- modules/erlang/mod_erlang.h | 2 +-
- 2 files changed, 180 insertions(+), 132 deletions(-)
-
-diff --git a/modules/erlang/mod_erlang.c b/modules/erlang/mod_erlang.c
-index 032a037..b8ab98b 100644
---- a/modules/erlang/mod_erlang.c
-+++ b/modules/erlang/mod_erlang.c
-@@ -72,6 +72,11 @@ static int fixup_send(void** param, int param_no);
- static int fixup_reg(void** param, int param_no);
- static int fixup_reply(void** param, int param_no);
-
-+int fixup_free_rpc(void** param, int param_no);
-+int fixup_free_reg(void** param, int param_no);
-+int fixup_free_send(void** param, int param_no);
-+int fixup_free_reply(void** param, int param_no);
-+
- /* initialize common vars */
- str cookie = STR_NULL;
- int trace_level = 0;
-@@ -176,10 +181,10 @@ static param_export_t parameters[] =
-
- static cmd_export_t commands[] =
- {
-- {"erl_rpc", (cmd_function)erl_rpc, 4, fixup_rpc, 0, ANY_ROUTE},
-- {"erl_send", (cmd_function)erl_send_k, 2, fixup_send, 0, ANY_ROUTE},
-- {"erl_reg_send", (cmd_function)erl_reg_send_k, 2, fixup_reg, 0, ANY_ROUTE},
-- {"erl_reply", (cmd_function)erl_reply_k, 1, fixup_reply, 0, EVENT_ROUTE},
-+ {"erl_rpc", (cmd_function)erl_rpc, 4, fixup_rpc, fixup_free_rpc, ANY_ROUTE},
-+ {"erl_send", (cmd_function)erl_send_k, 2, fixup_send, fixup_free_send, ANY_ROUTE},
-+ {"erl_reg_send", (cmd_function)erl_reg_send_k, 2, fixup_reg, fixup_free_reg, ANY_ROUTE},
-+ {"erl_reply", (cmd_function)erl_reply_k, 1, fixup_reply, fixup_free_reply, EVENT_ROUTE},
- {"load_erl",(cmd_function)load_erl,0, 0, 0, 0}, /* API loader */
- { 0, 0, 0, 0, 0, 0 }
- };
-@@ -434,7 +439,7 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
- sr_xavp_t *xreq=NULL;
- sr_xavp_t *xrepl=NULL;
- pv_spec_t sp;
-- pv_spec_t *nsp = NULL;
-+ pv_spec_t *nsp;
- pv_param_t pvp;
- pv_name_t *pvn;
- pv_index_t *pvi;
-@@ -446,7 +451,7 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
-
- switch (m->type) {
- case ERL_PARAM_FPARAM:
-- if(get_str_fparam(&module,msg,&m->value.fp)) {
-+ if(get_str_fparam(&module,msg,m->value.fp)) {
- LM_ERR("can't get module name\n");
- }
- break;
-@@ -457,7 +462,7 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
-
- switch (f->type) {
- case ERL_PARAM_FPARAM:
-- if(get_str_fparam(&function,msg,&f->value.fp)) {
-+ if(get_str_fparam(&function,msg,f->value.fp)) {
- LM_ERR("can't get function name\n");
- }
- break;
-@@ -468,7 +473,7 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
-
- switch(a->type){
- case ERL_PARAM_FPARAM:
-- if(get_str_fparam(&vname,msg,&a->value.fp)){
-+ if(get_str_fparam(&vname,msg,a->value.fp)){
- LM_ERR("can't get name of arguments parameter\n");
- return -1;
- }
-@@ -482,13 +487,8 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
- }
- break;
- case ERL_PARAM_XBUFF_SPEC:
-- sp = a->value.sp;
-- pvp = sp.pvp; /* work on copy */
--
-- if (pvp.pvn.type != PV_NAME_INTSTR || !(pvp.pvn.u.isname.type & AVP_NAME_STR)) {
-- LM_ERR("unsupported name of list\n");
-- return -1;
-- }
-+ nsp = NULL;
-+ pvp = a->value.sp.pvp; /* work on copy */
-
- if( pvp.pvn.type == PV_NAME_PVAR) {
- nsp = pvp.pvn.u.dname;
-@@ -497,9 +497,11 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
- if (nsp) {
- pvi = &nsp->pvp.pvi;
- pvn = &nsp->pvp.pvn;
-+ sp = *nsp;
- } else {
- pvi = &pvp.pvi;
- pvn = &pvp.pvn;
-+ sp = a->value.sp;
- }
-
- if (sp.setf == pv_list_set ) {
-@@ -512,7 +514,6 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
-
- /* fix index */
- attr = xbuff_get_attr_flags(pvi->type);
-- pvi->type = xbuff_fix_index(pvi->type);
-
- /* get the index */
- if(pv_get_spec_index(msg, &pvp, &idx, &idxf))
-@@ -553,20 +554,15 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
-
- switch(r->type){
- case ERL_PARAM_FPARAM:
-- if(get_str_fparam(&vname,msg,&r->value.fp)){
-+ if(get_str_fparam(&vname,msg,r->value.fp)){
- LM_ERR("can't get name of arguments parameter\n");
- return -1;
- }
- xrepl = pv_xbuff_get_xbuff(&vname);
- break;
- case ERL_PARAM_XBUFF_SPEC:
-- sp = r->value.sp;
-- pvp = sp.pvp; /* work on copy */
--
-- if (pvp.pvn.type != PV_NAME_INTSTR || !(pvp.pvn.u.isname.type & AVP_NAME_STR)) {
-- LM_ERR("unsupported name of xbuff\n");
-- return -1;
-- }
-+ nsp = NULL;
-+ pvp = r->value.sp.pvp; /* work on copy */
-
- if( pvp.pvn.type == PV_NAME_PVAR) {
- nsp = pvp.pvn.u.dname;
-@@ -575,9 +571,11 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
- if (nsp) {
- pvi = &nsp->pvp.pvi;
- pvn = &nsp->pvp.pvn;
-+ sp = *nsp;
- } else {
- pvi = &pvp.pvi;
- pvn = &pvp.pvn;
-+ sp = a->value.sp;
- }
-
- if (sp.setf == pv_xbuff_set ) {
-@@ -589,7 +587,6 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
-
- /* fix index */
- attr = xbuff_get_attr_flags(pvi->type);
-- pvi->type = xbuff_fix_index(pvi->type);
-
- /* get the index */
- if(pv_get_spec_index(msg, &pvp, &idx, &idxf))
-@@ -653,6 +650,7 @@ static int erl_rpc(struct sip_msg *msg, char *_m, char *_f, char *_a, char *_r)
- static int fixup_rpc(void** param, int param_no)
- {
- erl_param_t *erl_param;
-+ pv_spec_p psp;
-
- str s;
-
-@@ -669,7 +667,7 @@ static int fixup_rpc(void** param, int param_no)
- return -1;
- }
- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-+ erl_param->value.fp = (fparam_t*)*param;
- }
-
- if (param_no==3 || param_no==4) {
-@@ -689,22 +687,19 @@ static int fixup_rpc(void** param, int param_no)
- return E_UNSPEC;
- }
- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-- } else if(pv_parse_spec( &s, &erl_param->value.sp)==NULL || erl_param->value.sp.type!=PVT_OTHER) {
--
-- /* only XBUFF is accepted for args and reply */
-- LM_ERR("wrong parameter #%d: accepted types are list of xbuff\n",param_no);
-- pv_spec_free(&erl_param->value.sp);
-- pkg_free((void*)erl_param);
-- return E_UNSPEC;
-+ erl_param->value.fp = (fparam_t*)*param;
- } else {
- /* lets check what is acceptable */
-- if (erl_param->value.sp.setf != pv_list_set && erl_param->value.sp.setf != pv_xbuff_set) {
-- LM_ERR("wrong parameter #%d: accepted types are list of xbuff\n",param_no);
-+ psp = (pv_spec_p)erl_param->value.sp.pvp.pvn.u.dname;
-+
-+ if (psp->setf != pv_list_set && psp->setf != pv_xbuff_set) {
-+ LM_ERR("wrong parameter #%d: accepted types are list or xbuff\n",param_no);
-+ pv_spec_free(&erl_param->value.sp);
- pkg_free((void*)erl_param);
- return E_UNSPEC;
- }
- erl_param->type = ERL_PARAM_XBUFF_SPEC;
-+ LM_ERR("erl_param->value.sp.type=%d\n",erl_param->value.sp.type);
- }
- }
-
-@@ -713,6 +708,28 @@ static int fixup_rpc(void** param, int param_no)
- return 0;
- }
-
-+int fixup_free_rpc(void** param, int param_no) {
-+
-+ erl_param_t *erl_param;
-+
-+ erl_param = (erl_param_t*)*param;
-+
-+ if(param_no==1 || param_no==2) {
-+ return fixup_free_fparam_2((void**)&erl_param->value.fp,param_no);
-+ }
-+
-+ if (param_no==3 || param_no==4) {
-+ LM_ERR("erl_param->value.sp.type=%d\n",erl_param->value.sp.type);
-+ if (erl_param->value.sp.type == PVT_OTHER) {
-+ pv_spec_free((pv_spec_p)erl_param->value.sp.pvp.pvn.u.dname);
-+ } else if (erl_param->value.sp.pvp.pvn.type == PV_NAME_INTSTR) {
-+ return fixup_free_fparam_2((void**)&erl_param->value.fp,param_no);
-+ }
-+ }
-+
-+ return 0;
-+}
-+
- static int erl_reg_send_k(struct sip_msg *msg, char *_server, char *_emsg)
- {
- erl_param_t *param_server=(erl_param_t*)_server;
-@@ -733,7 +750,7 @@ static int erl_reg_send_k(struct sip_msg *msg, char *_server, char *_emsg)
-
- switch (param_server->type) {
- case ERL_PARAM_FPARAM:
-- if(get_str_fparam(&server,msg,¶m_server->value.fp)) {
-+ if(get_str_fparam(&server,msg,param_server->value.fp)) {
- LM_ERR("can't get server process name\n");
- }
- break;
-@@ -746,7 +763,7 @@ static int erl_reg_send_k(struct sip_msg *msg, char *_server, char *_emsg)
-
- switch(param_emsg->type){
- case ERL_PARAM_FPARAM:
-- if(get_str_fparam(&str_msg,msg,¶m_emsg->value.fp)){
-+ if(get_str_fparam(&str_msg,msg,param_emsg->value.fp)){
- LM_ERR("can't get emsg parameter\n");
- goto err;
- }
-@@ -755,13 +772,7 @@ static int erl_reg_send_k(struct sip_msg *msg, char *_server, char *_emsg)
-
- break;
- case ERL_PARAM_XBUFF_SPEC:
-- sp = param_emsg->value.sp;
-- pvp = sp.pvp; /* work on copy */
--
-- if (pvp.pvn.type != PV_NAME_INTSTR || !(pvp.pvn.u.isname.type & AVP_NAME_STR)) {
-- LM_ERR("unsupported name of list\n");
-- return -1;
-- }
-+ pvp = param_emsg->value.sp.pvp; /* work on copy */
-
- if( pvp.pvn.type == PV_NAME_PVAR) {
- nsp = pvp.pvn.u.dname;
-@@ -770,9 +781,11 @@ static int erl_reg_send_k(struct sip_msg *msg, char *_server, char *_emsg)
- if (nsp) {
- pvi = &nsp->pvp.pvi;
- pvn = &nsp->pvp.pvn;
-+ sp = *nsp;
- } else {
- pvi = &pvp.pvi;
- pvn = &pvp.pvn;
-+ sp = param_emsg->value.sp;
- }
-
- if (sp.setf == pv_list_set ) {
-@@ -785,7 +798,6 @@ static int erl_reg_send_k(struct sip_msg *msg, char *_server, char *_emsg)
-
- /* fix index */
- attr = xbuff_get_attr_flags(pvi->type);
-- pvi->type = xbuff_fix_index(pvi->type);
-
- /* get the index */
- if(pv_get_spec_index(msg, &pvp, &idx, &idxf))
-@@ -843,6 +855,7 @@ err:
- static int fixup_reg(void** param, int param_no)
- {
- erl_param_t *erl_param;
-+ pv_spec_p psp;
-
- str s;
-
-@@ -861,7 +874,7 @@ static int fixup_reg(void** param, int param_no)
- return -1;
- }
- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-+ erl_param->value.fp = (fparam_t*)*param;
- }
-
- if (param_no==2) {
-@@ -881,30 +894,27 @@ static int fixup_reg(void** param, int param_no)
- return E_UNSPEC;
- }
- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-- } else if(pv_parse_spec( &s, &erl_param->value.sp)==NULL) {
--
-- /* only XBUFF is accepted for emsg and reply */
-- LM_ERR("wrong parameter #%d\n",param_no);
-- pv_spec_free(&erl_param->value.sp);
-- pkg_free((void*)erl_param);
-- return E_UNSPEC;
-+ erl_param->value.fp = (fparam_t*)*param;
- } else {
-- if (erl_param->value.sp.type ==PVT_XAVP) {
-+ if (erl_param->value.sp.type == PVT_XAVP) {
- LM_ERR("XAVP not acceptable for parameter #%d\n",param_no);
- pkg_free((void*)erl_param);
- return E_UNSPEC;
- }
-
-- if (erl_param->value.sp.setf == pv_list_set
-- || erl_param->value.sp.setf == pv_xbuff_set
-- || erl_param->value.sp.setf == pv_tuple_set
-- || erl_param->value.sp.setf == pv_atom_set) {
-+ psp = (pv_spec_p)erl_param->value.sp.pvp.pvn.u.dname;
-+
-+ if (psp->setf == pv_list_set
-+ || psp->setf == pv_xbuff_set
-+ || psp->setf == pv_tuple_set
-+ || psp->setf == pv_atom_set) {
-
- erl_param->type = ERL_PARAM_XBUFF_SPEC;
- } else {
-- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-+ LM_ERR("wrong parameter #%d\n",param_no);
-+ pv_spec_free(&erl_param->value.sp);
-+ pkg_free((void*)erl_param);
-+ return E_UNSPEC;
- }
- }
- }
-@@ -914,6 +924,28 @@ static int fixup_reg(void** param, int param_no)
- return 0;
- }
-
-+int fixup_free_reg(void** param, int param_no) {
-+
-+ erl_param_t *erl_param;
-+
-+ erl_param = (erl_param_t*)*param;
-+
-+ if(param_no==1) {
-+ return fixup_free_fparam_1((void**)&erl_param->value.fp,param_no);
-+ }
-+
-+ if (param_no==2) {
-+ LM_ERR("erl_param->value.sp.type=%d\n",erl_param->value.sp.type);
-+ if (erl_param->value.sp.type == PVT_OTHER) {
-+ pv_spec_free((pv_spec_p)erl_param->value.sp.pvp.pvn.u.dname);
-+ } else if (erl_param->value.sp.pvp.pvn.type == PV_NAME_INTSTR) {
-+ return fixup_free_fparam_2((void**)&erl_param->value.fp,param_no);
-+ }
-+ }
-+
-+ return 0;
-+}
-+
- static int erl_reply_k(struct sip_msg *msg, char *_emsg)
- {
- erl_param_t *param_emsg=(erl_param_t*)_emsg;
-@@ -934,7 +966,7 @@ static int erl_reply_k(struct sip_msg *msg, char *_emsg)
-
- switch(param_emsg->type){
- case ERL_PARAM_FPARAM:
-- if(get_str_fparam(&str_msg,msg,¶m_emsg->value.fp)){
-+ if(get_str_fparam(&str_msg,msg,param_emsg->value.fp)){
- LM_ERR("can't get emsg parameter\n");
- goto err;
- }
-@@ -943,13 +975,7 @@ static int erl_reply_k(struct sip_msg *msg, char *_emsg)
-
- break;
- case ERL_PARAM_XBUFF_SPEC:
-- sp = param_emsg->value.sp;
-- pvp = sp.pvp; /* work on copy */
--
-- if (pvp.pvn.type != PV_NAME_INTSTR || !(pvp.pvn.u.isname.type & AVP_NAME_STR)) {
-- LM_ERR("unsupported name of list\n");
-- return -1;
-- }
-+ pvp = param_emsg->value.sp.pvp; /* work on copy */
-
- if( pvp.pvn.type == PV_NAME_PVAR) {
- nsp = pvp.pvn.u.dname;
-@@ -958,9 +984,11 @@ static int erl_reply_k(struct sip_msg *msg, char *_emsg)
- if (nsp) {
- pvi = &nsp->pvp.pvi;
- pvn = &nsp->pvp.pvn;
-+ sp = *nsp;
- } else {
- pvi = &pvp.pvi;
- pvn = &pvp.pvn;
-+ sp = param_emsg->value.sp;
- }
-
- if (sp.setf == pv_list_set ) {
-@@ -1031,6 +1059,7 @@ err:
- static int fixup_reply(void** param, int param_no)
- {
- erl_param_t *erl_param;
-+ pv_spec_p psp;
-
- str s;
-
-@@ -1060,14 +1089,7 @@ static int fixup_reply(void** param, int param_no)
- return E_UNSPEC;
- }
- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-- } else if(pv_parse_spec( &s, &erl_param->value.sp)==NULL) {
--
-- /* only XBUFF is accepted for emsg and reply */
-- LM_ERR("wrong parameter #%d\n",param_no);
-- pv_spec_free(&erl_param->value.sp);
-- pkg_free((void*)erl_param);
-- return E_UNSPEC;
-+ erl_param->value.fp = (fparam_t*)*param;
- } else {
- if (erl_param->value.sp.type ==PVT_XAVP) {
- LM_ERR("XAVP not acceptable for parameter #%d\n",param_no);
-@@ -1075,15 +1097,19 @@ static int fixup_reply(void** param, int param_no)
- return E_UNSPEC;
- }
-
-- if (erl_param->value.sp.setf == pv_list_set
-- || erl_param->value.sp.setf == pv_xbuff_set
-- || erl_param->value.sp.setf == pv_tuple_set
-- || erl_param->value.sp.setf == pv_atom_set) {
-+ psp = (pv_spec_p)erl_param->value.sp.pvp.pvn.u.dname;
-+
-+ if (psp->setf == pv_list_set
-+ || psp->setf == pv_xbuff_set
-+ || psp->setf == pv_tuple_set
-+ || psp->setf == pv_atom_set) {
-
- erl_param->type = ERL_PARAM_XBUFF_SPEC;
- } else {
-- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-+ LM_ERR("wrong parameter #%d\n",param_no);
-+ pv_spec_free(&erl_param->value.sp);
-+ pkg_free((void*)erl_param);
-+ return E_UNSPEC;
- }
- }
- }
-@@ -1093,6 +1119,24 @@ static int fixup_reply(void** param, int param_no)
- return 0;
- }
-
-+int fixup_free_reply(void** param, int param_no) {
-+
-+ erl_param_t *erl_param;
-+
-+ erl_param = (erl_param_t*)*param;
-+
-+ if (param_no==1) {
-+ LM_ERR("erl_param->value.sp.type=%d\n",erl_param->value.sp.type);
-+ if (erl_param->value.sp.type == PVT_OTHER) {
-+ pv_spec_free((pv_spec_p)erl_param->value.sp.pvp.pvn.u.dname);
-+ } else if (erl_param->value.sp.pvp.pvn.type == PV_NAME_INTSTR) {
-+ return fixup_free_fparam_2((void**)&erl_param->value.fp,param_no);
-+ }
-+ }
-+
-+ return 0;
-+}
-+
- static int erl_send_k(struct sip_msg *msg, char *_pid, char *_emsg)
- {
- erl_param_t *param_pid=(erl_param_t*)_pid;
-@@ -1101,7 +1145,7 @@ static int erl_send_k(struct sip_msg *msg, char *_pid, char *_emsg)
- str str_msg;
- sr_xavp_t *xmsg=NULL;
- pv_spec_t sp;
-- pv_spec_t *nsp = NULL;
-+ pv_spec_t *nsp;
- pv_param_t pvp;
- pv_name_t *pvn;
- pv_index_t *pvi;
-@@ -1113,13 +1157,8 @@ static int erl_send_k(struct sip_msg *msg, char *_pid, char *_emsg)
-
- switch (param_pid->type) {
- case ERL_PARAM_XBUFF_SPEC:
-- sp = param_pid->value.sp;
-- pvp = sp.pvp; /* work on copy */
--
-- if (pvp.pvn.type != PV_NAME_INTSTR || !(pvp.pvn.u.isname.type & AVP_NAME_STR)) {
-- LM_ERR("unsupported name of pid\n");
-- return -1;
-- }
-+ nsp = NULL;
-+ pvp = param_pid->value.sp.pvp; /* work on copy */
-
- if( pvp.pvn.type == PV_NAME_PVAR) {
- nsp = pvp.pvn.u.dname;
-@@ -1128,9 +1167,11 @@ static int erl_send_k(struct sip_msg *msg, char *_pid, char *_emsg)
- if (nsp) {
- pvi = &nsp->pvp.pvi;
- pvn = &nsp->pvp.pvn;
-+ sp = *nsp;
- } else {
- pvi = &pvp.pvi;
- pvn = &pvp.pvn;
-+ sp = param_pid->value.sp;
- }
-
- if (sp.getf == pv_pid_get ) {
-@@ -1144,7 +1185,6 @@ static int erl_send_k(struct sip_msg *msg, char *_pid, char *_emsg)
-
- /* fix index */
- attr = xbuff_get_attr_flags(pvi->type);
-- pvi->type = xbuff_fix_index(pvi->type);
-
- /* get the index */
- if(pv_get_spec_index(msg, &pvp, &idx, &idxf))
-@@ -1190,7 +1230,7 @@ static int erl_send_k(struct sip_msg *msg, char *_pid, char *_emsg)
-
- switch(param_emsg->type){
- case ERL_PARAM_FPARAM:
-- if(get_str_fparam(&str_msg,msg,¶m_emsg->value.fp)){
-+ if(get_str_fparam(&str_msg,msg,param_emsg->value.fp)){
- LM_ERR("can't get emsg parameter\n");
- goto err;
- }
-@@ -1199,13 +1239,8 @@ static int erl_send_k(struct sip_msg *msg, char *_pid, char *_emsg)
-
- break;
- case ERL_PARAM_XBUFF_SPEC:
-- sp = param_emsg->value.sp;
-- pvp = sp.pvp; /* work on copy */
--
-- if (pvp.pvn.type != PV_NAME_INTSTR || !(pvp.pvn.u.isname.type & AVP_NAME_STR)) {
-- LM_ERR("unsupported name of list\n");
-- return -1;
-- }
-+ nsp = NULL;
-+ pvp = param_emsg->value.sp.pvp; /* work on copy */
-
- if( pvp.pvn.type == PV_NAME_PVAR) {
- nsp = pvp.pvn.u.dname;
-@@ -1214,9 +1249,11 @@ static int erl_send_k(struct sip_msg *msg, char *_pid, char *_emsg)
- if (nsp) {
- pvi = &nsp->pvp.pvi;
- pvn = &nsp->pvp.pvn;
-+ sp = *nsp;
- } else {
- pvi = &pvp.pvi;
- pvn = &pvp.pvn;
-+ sp = param_emsg->value.sp;
- }
-
- if (sp.getf == pv_list_get ) {
-@@ -1233,7 +1270,6 @@ static int erl_send_k(struct sip_msg *msg, char *_pid, char *_emsg)
-
- /* fix index */
- attr = xbuff_get_attr_flags(pvi->type);
-- pvi->type = xbuff_fix_index(pvi->type);
-
- /* get the index */
- if(pv_get_spec_index(msg, &pvp, &idx, &idxf))
-@@ -1291,6 +1327,7 @@ err:
- static int fixup_send(void** param, int param_no)
- {
- erl_param_t *erl_param;
-+ pv_spec_p psp;
-
- str s;
-
-@@ -1320,27 +1357,24 @@ static int fixup_send(void** param, int param_no)
- return E_UNSPEC;
- }
- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-- } else if(pv_parse_spec( &s, &erl_param->value.sp)==NULL) {
--
-- /* only XBUFF is accepted for emsg */
-- LM_ERR("wrong parameter #%d\n",param_no);
-- pv_spec_free(&erl_param->value.sp);
-- pkg_free((void*)erl_param);
-- return E_UNSPEC;
-- } else {
-- if (erl_param->value.sp.type ==PVT_XAVP) {
-+ erl_param->value.fp = (fparam_t*)*param;
-+ }
-+ else {
-+ if (erl_param->value.sp.type == PVT_XAVP) {
- LM_ERR("XAVP not acceptable for parameter #%d\n",param_no);
- pkg_free((void*)erl_param);
- return E_UNSPEC;
- }
-
-- if (erl_param->value.sp.getf == pv_pid_get
-- || erl_param->value.sp.getf == pv_xbuff_get) {
-+ psp = (pv_spec_p)erl_param->value.sp.pvp.pvn.u.dname;
-+
-+ if (psp->getf == pv_pid_get || psp->getf == pv_xbuff_get) {
- erl_param->type = ERL_PARAM_XBUFF_SPEC;
- } else {
-- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-+ LM_ERR("wrong parameter #%d\n",param_no);
-+ pv_spec_free(&erl_param->value.sp);
-+ pkg_free((void*)erl_param);
-+ return E_UNSPEC;
- }
- }
- }
-@@ -1362,14 +1396,7 @@ static int fixup_send(void** param, int param_no)
- return E_UNSPEC;
- }
- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-- } else if(pv_parse_spec( &s, &erl_param->value.sp)==NULL) {
--
-- /* only XBUFF is accepted for emsg */
-- LM_ERR("wrong parameter #%d\n",param_no);
-- pv_spec_free(&erl_param->value.sp);
-- pkg_free((void*)erl_param);
-- return E_UNSPEC;
-+ erl_param->value.fp = (fparam_t*)*param;
- } else {
- if (erl_param->value.sp.type ==PVT_XAVP) {
- LM_ERR("XAVP not acceptable for parameter #%d\n",param_no);
-@@ -1377,16 +1404,20 @@ static int fixup_send(void** param, int param_no)
- return E_UNSPEC;
- }
-
-- if (erl_param->value.sp.getf == pv_list_get
-- || erl_param->value.sp.getf == pv_xbuff_get
-- || erl_param->value.sp.getf == pv_tuple_get
-- || erl_param->value.sp.getf == pv_atom_get
-- || erl_param->value.sp.getf == pv_pid_get) {
-+ psp = (pv_spec_p)erl_param->value.sp.pvp.pvn.u.dname;
-+
-+ if (psp->getf == pv_list_get
-+ || psp->getf == pv_xbuff_get
-+ || psp->getf == pv_tuple_get
-+ || psp->getf == pv_atom_get
-+ || psp->getf == pv_pid_get) {
-
- erl_param->type = ERL_PARAM_XBUFF_SPEC;
- } else {
-- erl_param->type = ERL_PARAM_FPARAM;
-- erl_param->value.fp = *(fparam_t*)*param;
-+ LM_ERR("wrong parameter #%d\n",param_no);
-+ pv_spec_free(&erl_param->value.sp);
-+ pkg_free((void*)erl_param);
-+ return E_UNSPEC;
- }
- }
- }
-@@ -1395,3 +1426,20 @@ static int fixup_send(void** param, int param_no)
-
- return 0;
- }
-+
-+int fixup_free_send(void** param, int param_no) {
-+
-+ erl_param_t *erl_param;
-+
-+ erl_param = (erl_param_t*)*param;
-+
-+ if (param_no==1 || param_no==2) {
-+ if (erl_param->value.sp.type == PVT_OTHER) {
-+ pv_spec_free((pv_spec_p)erl_param->value.sp.pvp.pvn.u.dname);
-+ } else if (erl_param->value.sp.pvp.pvn.type == PV_NAME_INTSTR) {
-+ return fixup_free_fparam_2((void**)&erl_param->value.fp,param_no);
-+ }
-+ }
-+
-+ return 0;
-+}
-diff --git a/modules/erlang/mod_erlang.h b/modules/erlang/mod_erlang.h
-index 34b06a6..3e06e39 100644
---- a/modules/erlang/mod_erlang.h
-+++ b/modules/erlang/mod_erlang.h
-@@ -63,7 +63,7 @@ typedef enum {
- typedef struct erl_param_s {
- erl_param_type type;
- union {
-- fparam_t fp;
-+ fparam_t *fp;
- pv_spec_t sp;
- } value;
- } erl_param_t;
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0048-json-replaced-use-of-obsolete-function-json_object_o.patch b/debian/patches/upstream/0048-json-replaced-use-of-obsolete-function-json_object_o.patch
deleted file mode 100644
index 4f619a6..0000000
--- a/debian/patches/upstream/0048-json-replaced-use-of-obsolete-function-json_object_o.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-From 2700d7b8df738f9e5db82dca87cbab5549f2e0d1 Mon Sep 17 00:00:00 2001
-From: Daniel-Constantin Mierla <miconda at gmail.com>
-Date: Mon, 25 Apr 2016 08:54:45 +0200
-Subject: [PATCH] json: replaced use of obsolete function
- json_object_object_get()
-
-- reported by Olle E. Johansson, GH #579
-
-(cherry picked from commit 8b9fd4fa40abfc40ecd537948036aa91b908615d)
----
- modules/json/json_funcs.c | 21 ++++++++++++++-------
- 1 file changed, 14 insertions(+), 7 deletions(-)
-
-diff --git a/modules/json/json_funcs.c b/modules/json/json_funcs.c
-index 106eef1..4d73c73 100644
---- a/modules/json/json_funcs.c
-+++ b/modules/json/json_funcs.c
-@@ -39,6 +39,8 @@ int json_get_field(struct sip_msg* msg, char* json, char* field, char* dst)
- pv_value_t dst_val;
- char *value;
- struct json_object *j = NULL;
-+ struct json_object *oj = NULL;
-+ int ret;
-
- if (fixup_get_svalue(msg, (gparam_p)json, &json_s) != 0) {
- LM_ERR("cannot get json string value\n");
-@@ -61,13 +63,18 @@ int json_get_field(struct sip_msg* msg, char* json, char* field, char* dst)
- return -1;
- }
-
-- value = (char*)json_object_to_json_string(json_object_object_get(j, field_s.s));
--
-- dst_val.rs.s = value;
-- dst_val.rs.len = strlen(value);
-- dst_val.flags = PV_VAL_STR;
-- dst_pv->setf(msg, &dst_pv->pvp, (int)EQ_T, &dst_val);
-+ json_object_object_get_ex(j, field_s.s, &oj);
-+ if(oj!=NULL) {
-+ value = (char*)json_object_to_json_string(oj);
-+ dst_val.rs.s = value;
-+ dst_val.rs.len = strlen(value);
-+ dst_val.flags = PV_VAL_STR;
-+ dst_pv->setf(msg, &dst_pv->pvp, (int)EQ_T, &dst_val);
-+ ret = 1;
-+ } else {
-+ ret = -1;
-+ }
-
- if(j!=NULL) json_object_put(j);
-- return 1;
-+ return ret;
- }
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0049-jsonrpc-c-replaced-use-of-obsolete-function-json_obj.patch b/debian/patches/upstream/0049-jsonrpc-c-replaced-use-of-obsolete-function-json_obj.patch
deleted file mode 100644
index 783a6cf..0000000
--- a/debian/patches/upstream/0049-jsonrpc-c-replaced-use-of-obsolete-function-json_obj.patch
+++ /dev/null
@@ -1,92 +0,0 @@
-From 528842d4dfea3d6785e6cee0cd3fb6411ee3dc7d Mon Sep 17 00:00:00 2001
-From: Daniel-Constantin Mierla <miconda at gmail.com>
-Date: Mon, 25 Apr 2016 08:56:00 +0200
-Subject: [PATCH] jsonrpc-c: replaced use of obsolete function
- json_object_object_get()
-
-(cherry picked from commit be02b3f11c269d3eeeb52e1cd0056d7d77be2e4c)
----
- modules/jsonrpc-c/jsonrpc.c | 28 ++++++++++++++++------------
- 1 file changed, 16 insertions(+), 12 deletions(-)
-
-diff --git a/modules/jsonrpc-c/jsonrpc.c b/modules/jsonrpc-c/jsonrpc.c
-index 7baed54..834a7dd 100644
---- a/modules/jsonrpc-c/jsonrpc.c
-+++ b/modules/jsonrpc-c/jsonrpc.c
-@@ -70,34 +70,38 @@ jsonrpc_request_t* build_jsonrpc_request(char *method, json_object *params, char
- return req;
- }
-
--json_object* build_jsonrpc_notification(char *method, json_object *params)
-+json_object* build_jsonrpc_notification(char *method, json_object *params)
- {
- json_object *req = json_object_new_object();
- json_object_object_add(req, "jsonrpc", json_object_new_string("2.0"));
- json_object_object_add(req, "method", json_object_new_string(method));
- json_object_object_add(req, "params", params);
-
-- return req;
-+ return req;
- }
-
-
- int handle_jsonrpc_response(json_object *response)
- {
-- jsonrpc_request_t *req;
-- json_object *_id = json_object_object_get(response, "id");
-- int id = json_object_get_int(_id);
--
-+ jsonrpc_request_t *req;
-+ json_object *_id = NULL;
-+ int id = 0;
-+ json_object *result = NULL;
-+
-+ json_object_object_get_ex(response, "id", &_id);
-+ id = json_object_get_int(_id);
- if (!(req = get_request(id))) {
- json_object_put(response);
- return -1;
- }
-
-- json_object *result = json_object_object_get(response, "result");
--
-+ json_object_object_get_ex(response, "result", &result);
-+
- if (result) {
- req->cbfunc(result, req->cbdata, 0);
- } else {
-- json_object *error = json_object_object_get(response, "error");
-+ json_object *error = NULL;
-+ json_object_object_get_ex(response, "error", &error);
- if (error) {
- req->cbfunc(error, req->cbdata, 1);
- } else {
-@@ -105,7 +109,7 @@ int handle_jsonrpc_response(json_object *response)
- return -1;
- }
- }
--
-+
- if (req->timer_ev) {
- close(req->timerfd);
- event_del(req->timer_ev);
-@@ -125,14 +129,14 @@ jsonrpc_request_t* get_request(int id) {
- int key = id_hash(id);
- jsonrpc_request_t *req, *prev_req = NULL;
- req = request_table[key];
--
-+
- while (req && req->id != id) {
- prev_req = req;
- if (!(req = req->next)) {
- break;
- };
- }
--
-+
- if (req && req->id == id) {
- if (prev_req != NULL) {
- prev_req-> next = req->next;
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0050-core-remove-ending-parenthesis-in-ifdef-condition.patch b/debian/patches/upstream/0050-core-remove-ending-parenthesis-in-ifdef-condition.patch
deleted file mode 100644
index 415350b..0000000
--- a/debian/patches/upstream/0050-core-remove-ending-parenthesis-in-ifdef-condition.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 71f329c971d6ad18f7eda16a2b50b25e9efd3236 Mon Sep 17 00:00:00 2001
-From: Daniel-Constantin Mierla <miconda at gmail.com>
-Date: Wed, 20 Apr 2016 11:59:25 +0200
-Subject: [PATCH] core: remove ending parenthesis in ifdef condition
-
-warning: ISO C99 requires whitespace after the macro name
-sched_yield.h:34:20: warning: extra tokens at end of #ifndef directive
- #ifndef sched_yield()
-
-- reported by Victore Seva, GH #576
-
-(cherry picked from commit 34b67125424da7ce86b5cac77e30af0711fafac1)
----
- sched_yield.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/sched_yield.h b/sched_yield.h
-index 1f8546d..b63f90e 100644
---- a/sched_yield.h
-+++ b/sched_yield.h
-@@ -31,7 +31,7 @@
- #else
- #include <unistd.h>
- /* fake sched_yield */
--#ifndef sched_yield()
-+#ifndef sched_yield
- #define sched_yield() sleep(0)
- #endif
- #endif
---
-2.8.0.rc3
-
diff --git a/debian/patches/upstream/0051-Makefile.defs-detect-kfreebsd-OS-and-set-its-default.patch b/debian/patches/upstream/0051-Makefile.defs-detect-kfreebsd-OS-and-set-its-default.patch
deleted file mode 100644
index 9afe79d..0000000
--- a/debian/patches/upstream/0051-Makefile.defs-detect-kfreebsd-OS-and-set-its-default.patch
+++ /dev/null
@@ -1,83 +0,0 @@
-From 615b252510cee01dc6f24ac7d12f07dcb6b50366 Mon Sep 17 00:00:00 2001
-From: Daniel-Constantin Mierla <miconda at gmail.com>
-Date: Wed, 20 Apr 2016 12:02:09 +0200
-Subject: [PATCH] Makefile.defs: detect kfreebsd OS and set its default compile
- flags
-
-- combine the options of Linux with FreeBSD to use kqueue if available
-- reported by Victor Seva, GH #576
-
-(cherry picked from commit 4c6f879563adbbdee7c730549533a0d852e6cbef)
----
- Makefile.defs | 41 ++++++++++++++++++++++++++++++++++++++++-
- 1 file changed, 40 insertions(+), 1 deletion(-)
-
-diff --git a/Makefile.defs b/Makefile.defs
-index 245f9b4..1814caf 100644
---- a/Makefile.defs
-+++ b/Makefile.defs
-@@ -113,7 +113,7 @@ SER_VER = $(shell expr $(VERSION) \* 1000000 + $(PATCHLEVEL) \* 1000 + \
- $(SUBLEVEL) )
- RELEASE:=$(VERSION).$(PATCHLEVEL).$(SUBLEVEL)$(EXTRAVERSION)
- OS := $(shell uname -s | sed -e s/SunOS/solaris/ -e s/CYGWIN.*/cygwin/ \
-- | tr "[A-Z]" "[a-z]")
-+ | tr "[A-Z]" "[a-z]" | tr "/" "_")
-
- ifeq ($(OS),solaris)
- GETARCH=isainfo -n
-@@ -392,6 +392,13 @@ ifeq ($(OS), linux)
- LOCALBASE ?= /usr/local
- endif
-
-+ifeq ($(OS), gnu_kfreebsd)
-+ doc_dir = share/doc/$(MAIN_NAME)/
-+ man_dir = share/man/
-+ data_dir = share/$(MAIN_NAME)/
-+ LOCALBASE ?= /usr/local
-+endif
-+
- ifeq ($(OS), freebsd)
- doc_dir = share/doc/$(MAIN_NAME)/
- man_dir = man/
-@@ -1745,6 +1752,38 @@ ifeq ($(OS), linux)
- endif
- endif
-
-+ifeq ($(OS), gnu_kfreebsd)
-+# by default use futexes if available
-+ use_futex= yes
-+ C_DEFS+=-DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN -DHAVE_SCHED_YIELD \
-+ -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL -DHAVE_ALLOCA_H \
-+ -DHAVE_TIMEGM -DHAVE_SCHED_SETSCHEDULER -DUSE_RAW_SOCKS
-+ ifneq ($(found_lock_method), yes)
-+ #C_DEFS+= -DUSE_POSIX_SEM
-+ C_DEFS+=-DUSE_PTHREAD_MUTEX
-+ LIBS+= -lpthread
-+ #C_DEFS+= -DUSE_SYSV_SEM # try posix sems
-+ found_lock_method=yes
-+ else
-+ ifneq (,$(findstring -DUSE_POSIX_SEM, $(C_DEFS)))
-+ LIBS+=-lpthread
-+ endif
-+ ifneq (,$(findstring -DUSE_PTHREAD_MUTEX, $(C_DEFS)))
-+ LIBS+=-lpthread
-+ endif
-+ endif
-+
-+ # check for ver >= 4.1
-+ ifeq ($(shell [ $(OSREL_N) -gt 4001 ] && echo has_kqueue), has_kqueue)
-+ ifeq ($(NO_KQUEUE),)
-+ C_DEFS+=-DHAVE_KQUEUE
-+ endif
-+ endif
-+ ifeq ($(NO_SELECT),)
-+ C_DEFS+=-DHAVE_SELECT
-+ endif
-+endif
-+
- ifeq ($(OS), solaris)
- C_DEFS+= -DHAVE_GETIPNODEBYNAME -DHAVE_SYS_SOCKIO_H -DHAVE_SCHED_YIELD \
- -DHAVE_ALLOCA_H -DUSE_SIGACTION
---
-2.8.0.rc3
-
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-voip/kamailio.git
More information about the Pkg-voip-commits
mailing list