[Pkg-voip-commits] r10021 - in /kamailio/trunk/debian: ./ patches/ patches/upstream/

maniac-guest at alioth.debian.org maniac-guest at alioth.debian.org
Wed Nov 7 15:57:09 UTC 2012


Author: maniac-guest
Date: Wed Nov  7 15:57:08 2012
New Revision: 10021

URL: http://svn.debian.org/wsvn/pkg-voip/?sc=1&rev=10021
Log:
upstream fixes. ARM fix

Added:
    kamailio/trunk/debian/patches/arm_fix.patch
      - copied unchanged from r10018, kamailio/branches/wheezy/debian/patches/arm_fix.patch
    kamailio/trunk/debian/patches/upstream/0001-core-use-cloned-value-to-parse-pv-name-for-caching.patch
    kamailio/trunk/debian/patches/upstream/0006-allow-freeing-of-NULL-pointer-to-behave-like-standar.patch
    kamailio/trunk/debian/patches/upstream/0007-modules_k-siputils-Fix-memory-leak-in-uri_param-func.patch
Modified:
    kamailio/trunk/debian/changelog
    kamailio/trunk/debian/patches/series

Modified: kamailio/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-voip/kamailio/trunk/debian/changelog?rev=10021&op=diff
==============================================================================
--- kamailio/trunk/debian/changelog (original)
+++ kamailio/trunk/debian/changelog Wed Nov  7 15:57:08 2012
@@ -5,13 +5,16 @@
     + kambdb_recover binary is not in source.
   * debian/patches/upstream:
     + removed upstream fixes for the previous release.
+    + add upstream fixes.
+  * debian/patches:
     + removed plumb_md5.patch and plumb_md5_fixes.patch
       merged upstream ( Thanks miconda )
+    + arm_fix.patch (Closes: #690388) Thanks Matthias Klose <doko at debian.org>
   * debian/backports/squeeze:
     + remove call to dpkg-buildflags
     + do not apply hardening_flags.patch
 
- -- Victor Seva <linuxmaniac at torreviejawireless.org>  Mon, 22 Oct 2012 09:40:55 +0200
+ -- Victor Seva <linuxmaniac at torreviejawireless.org>  Wed, 07 Nov 2012 16:52:19 +0100
 
 kamailio (3.3.0-1) unstable; urgency=low
 

Modified: kamailio/trunk/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-voip/kamailio/trunk/debian/patches/series?rev=10021&op=diff
==============================================================================
--- kamailio/trunk/debian/patches/series (original)
+++ kamailio/trunk/debian/patches/series Wed Nov  7 15:57:08 2012
@@ -1,3 +1,7 @@
+upstream/0001-core-use-cloned-value-to-parse-pv-name-for-caching.patch
+upstream/0006-allow-freeing-of-NULL-pointer-to-behave-like-standar.patch
+upstream/0007-modules_k-siputils-Fix-memory-leak-in-uri_param-func.patch
 no_lib64_on_64_bits.patch
 no_INSTALL_file.patch
 fix_export.patch
+arm_fix.patch

Added: kamailio/trunk/debian/patches/upstream/0001-core-use-cloned-value-to-parse-pv-name-for-caching.patch
URL: http://svn.debian.org/wsvn/pkg-voip/kamailio/trunk/debian/patches/upstream/0001-core-use-cloned-value-to-parse-pv-name-for-caching.patch?rev=10021&op=file
==============================================================================
--- kamailio/trunk/debian/patches/upstream/0001-core-use-cloned-value-to-parse-pv-name-for-caching.patch (added)
+++ kamailio/trunk/debian/patches/upstream/0001-core-use-cloned-value-to-parse-pv-name-for-caching.patch Wed Nov  7 15:57:08 2012
@@ -1,0 +1,41 @@
+From 890f785bc05f137af624306f51874c17bef10d30 Mon Sep 17 00:00:00 2001
+From: Daniel-Constantin Mierla <miconda at gmail.com>
+Date: Thu, 25 Oct 2012 09:25:17 +0200
+Subject: [PATCH] core: use cloned value to parse pv name for caching
+
+- patch by Hugh Waite
+(cherry picked from commit 22f9a675863f85d934afa5e7c09061c66497042b)
+---
+ pvapi.c |   10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/pvapi.c b/pvapi.c
+index d1ebfe6..64878f2 100644
+--- a/pvapi.c
++++ b/pvapi.c
+@@ -272,17 +272,17 @@ pv_spec_t* pv_cache_add(str *name)
+ 		LM_ERR("no more memory\n");
+ 		return NULL;
+ 	}
+-	memset(pvn, 0, sizeof(pv_item_t) + name->len + 1);
+-	p = pv_parse_spec(name, &pvn->spec);
++	memset(pvn, 0, sizeof(pv_cache_t) + name->len + 1);
++	pvn->pvname.len = name->len;
++	pvn->pvname.s = (char*)pvn + sizeof(pv_cache_t);
++	memcpy(pvn->pvname.s, name->s, name->len);
++	p = pv_parse_spec(&pvn->pvname, &pvn->spec);
+ 
+ 	if(p==NULL)
+ 	{
+ 		pkg_free(pvn);
+ 		return NULL;
+ 	}
+-	pvn->pvname.len = name->len;
+-	pvn->pvname.s = (char*)pvn + sizeof(pv_cache_t);
+-	memcpy(pvn->pvname.s, name->s, name->len);
+ 	pvn->pvid = pvid;
+ 	pvn->next = _pv_cache[pvid%PV_CACHE_SIZE];
+ 	_pv_cache[pvid%PV_CACHE_SIZE] = pvn;
+-- 
+1.7.9.5
+

Added: kamailio/trunk/debian/patches/upstream/0006-allow-freeing-of-NULL-pointer-to-behave-like-standar.patch
URL: http://svn.debian.org/wsvn/pkg-voip/kamailio/trunk/debian/patches/upstream/0006-allow-freeing-of-NULL-pointer-to-behave-like-standar.patch?rev=10021&op=file
==============================================================================
--- kamailio/trunk/debian/patches/upstream/0006-allow-freeing-of-NULL-pointer-to-behave-like-standar.patch (added)
+++ kamailio/trunk/debian/patches/upstream/0006-allow-freeing-of-NULL-pointer-to-behave-like-standar.patch Wed Nov  7 15:57:08 2012
@@ -1,0 +1,40 @@
+From 020acff35f8e9dfa62aba8678a781a0f7bbb110b Mon Sep 17 00:00:00 2001
+From: Klaus Darilion <klaus.mailinglists at pernau.at>
+Date: Wed, 7 Nov 2012 13:55:55 +0000
+Subject: [PATCH] allow freeing of NULL pointer to behave like standard free()
+ function
+
+The memory functions provided to openssl needs to behave like standard
+memory functions, i.e. free(). Therefore, ser_free must accept NULL
+pointers, see: http://openssl.6102.n7.nabble.com/Custom-free-routine-is-invoked-with-NULL-argument-in-openssl-1-0-1-td25937.html
+As shm_free() aborts on null pointers, we have to check for null pointer
+here in the wrapper function.
+(cherry picked from commit 7c37f8d4dc311c64c12e0b03b5e312892f9d886c)
+---
+ modules/tls/tls_init.c |   10 +++++++++-
+ 1 file changed, 9 insertions(+), 1 deletion(-)
+
+diff --git a/modules/tls/tls_init.c b/modules/tls/tls_init.c
+index e409b5e..b629afa 100644
+--- a/modules/tls/tls_init.c
++++ b/modules/tls/tls_init.c
+@@ -295,7 +295,15 @@ static void* ser_realloc(void *ptr, size_t size)
+ 
+ static void ser_free(void *ptr)
+ {
+-	shm_free(ptr);
++	/* The memory functions provided to openssl needs to behave like standard
++	 * memory functions, i.e. free(). Therefore, ser_free must accept NULL
++	 * pointers, see: http://openssl.6102.n7.nabble.com/Custom-free-routine-is-invoked-with-NULL-argument-in-openssl-1-0-1-td25937.html
++	 * As shm_free() aborts on null pointers, we have to check for null pointer
++	 * here in the wrapper function.
++	 */
++	if (ptr) {
++		shm_free(ptr);
++	}
+ }
+ 
+ 
+-- 
+1.7.9.5
+

Added: kamailio/trunk/debian/patches/upstream/0007-modules_k-siputils-Fix-memory-leak-in-uri_param-func.patch
URL: http://svn.debian.org/wsvn/pkg-voip/kamailio/trunk/debian/patches/upstream/0007-modules_k-siputils-Fix-memory-leak-in-uri_param-func.patch?rev=10021&op=file
==============================================================================
--- kamailio/trunk/debian/patches/upstream/0007-modules_k-siputils-Fix-memory-leak-in-uri_param-func.patch (added)
+++ kamailio/trunk/debian/patches/upstream/0007-modules_k-siputils-Fix-memory-leak-in-uri_param-func.patch Wed Nov  7 15:57:08 2012
@@ -1,0 +1,57 @@
+From 858e4148f222e9f448d54c6bee45a53a8def7062 Mon Sep 17 00:00:00 2001
+From: Richard Fuchs <rfuchs at sipwise.com>
+Date: Wed, 7 Nov 2012 09:12:33 -0500
+Subject: [PATCH] modules_k/siputils: Fix memory leak in uri_param() function
+
+---
+ modules_k/siputils/checks.c |   16 +++++++---------
+ 1 file changed, 7 insertions(+), 9 deletions(-)
+
+diff --git a/modules_k/siputils/checks.c b/modules_k/siputils/checks.c
+index 6bbb72f..9794c9d 100644
+--- a/modules_k/siputils/checks.c
++++ b/modules_k/siputils/checks.c
+@@ -168,7 +168,7 @@ int uri_param_2(struct sip_msg* _msg, char* _param, char* _value)
+ 	str *param, *value, t;
+ 
+ 	param_hooks_t hooks;
+-	param_t* params;
++	param_t* params, *pit;
+ 
+ 	param = (str*)_param;
+ 	value = (str*)_value;
+@@ -185,25 +185,23 @@ int uri_param_2(struct sip_msg* _msg, char* _param, char* _value)
+ 	        return -1;
+ 	}
+ 
+-	while (params) {
+-		if ((params->name.len == param->len) &&
+-		    (strncmp(params->name.s, param->s, param->len) == 0)) {
++	for (pit = params; pit; pit = pit->next) {
++		if ((pit->name.len == param->len) &&
++		    (strncmp(pit->name.s, param->s, param->len) == 0)) {
+ 			if (value) {
+-				if ((value->len == params->body.len) &&
+-				    strncmp(value->s, params->body.s, value->len) == 0) {
++				if ((value->len == pit->body.len) &&
++				    strncmp(value->s, pit->body.s, value->len) == 0) {
+ 					goto ok;
+ 				} else {
+ 					goto nok;
+ 				}
+ 			} else {
+-				if (params->body.len > 0) {
++				if (pit->body.len > 0) {
+ 					goto nok;
+ 				} else {
+ 					goto ok;
+ 				}
+ 			}
+-		} else {
+-			params = params->next;
+ 		}
+ 	}
+ 	
+-- 
+1.7.9.5
+




More information about the Pkg-voip-commits mailing list