Module: sip-router
Branch: master
Commit: 6cfee82666b78400d5ff15c49aac1441cfbbaaf6
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=6cfee82…
Author: Marius Zbihlei <marius.zbihlei(a)1and1.ro>
Committer: Marius Zbihlei <marius.zbihlei(a)1and1.ro>
Date: Thu Nov 4 17:14:56 2010 +0200
core:forward.c Fixed small error caused by unlikely usage.
---
forward.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/forward.c b/forward.c
index 3d7aed1..175f54b 100644
--- a/forward.c
+++ b/forward.c
@@ -175,7 +175,7 @@ retry:
if( !mhomed_sock_cache_disabled ){
/* some Linux kernel versions (all?) along with other UNIXes don't re-bound the sock if already bound */
/* to un-bound a socket set sin_family to AF_UNSPEC and zero out the rest*/
- if (unlikely(connect(*temp_sock, &uncon.s, sockaddru_len(uncon))) < 0)
+ if (unlikely(connect(*temp_sock, &uncon.s, sockaddru_len(uncon)) < 0))
mhomed_sock_cache_disabled = 1;
}
Module: sip-router
Branch: master
Commit: ef0dd4e3f0837753ac18d58606078d8595f24dc6
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=ef0dd4e…
Author: Marius Zbihlei <marius.zbihlei(a)1and1.ro>
Committer: Marius Zbihlei <marius.zbihlei(a)1and1.ro>
Date: Thu Nov 4 16:11:41 2010 +0200
core/forward.c Fixed mhomed behavior.
As connect() dones't re-bound a UDP sock if the socket is already
bound to an interface, first unbind the socket by connecting to AF_UNSPEC
---
forward.c | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/forward.c b/forward.c
index 25bc11d..3d7aed1 100644
--- a/forward.c
+++ b/forward.c
@@ -131,6 +131,10 @@ struct socket_info* get_out_socket(union sockaddr_union* to, int proto)
union sockaddr_union from;
struct socket_info* si;
struct ip_addr ip;
+ union sockaddr_union uncon;
+
+ memset(&uncon, 0, sizeof(union sockaddr_union));
+ uncon.sin.sin_family = AF_UNSPEC;
if (unlikely(proto!=PROTO_UDP)) {
LOG(L_CRIT, "BUG: get_out_socket can only be called for UDP\n");
@@ -167,6 +171,14 @@ retry:
return 0;
}
}
+
+ if( !mhomed_sock_cache_disabled ){
+ /* some Linux kernel versions (all?) along with other UNIXes don't re-bound the sock if already bound */
+ /* to un-bound a socket set sin_family to AF_UNSPEC and zero out the rest*/
+ if (unlikely(connect(*temp_sock, &uncon.s, sockaddru_len(uncon))) < 0)
+ mhomed_sock_cache_disabled = 1;
+ }
+
if (unlikely(connect(*temp_sock, &to->s, sockaddru_len(*to))==-1)) {
if (unlikely(errno==EISCONN && !mhomed_sock_cache_disabled)){
/* no multiple connects support on the same socket */
Revision: 6050
http://openser.svn.sourceforge.net/openser/?rev=6050&view=rev
Author: mariuszbihlei
Date: 2010-11-04 13:07:25 +0000 (Thu, 04 Nov 2010)
Log Message:
-----------
core/forward.c Some Linux kernels, (tested on 2.6.26 and 2.6.32) don't re-bound a UDP sock if the socket is already
bound to an interface when doing connect().
Modified Paths:
--------------
branches/1.5/forward.c
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
Revision: 6049
http://openser.svn.sourceforge.net/openser/?rev=6049&view=rev
Author: timoreimann
Date: 2010-11-02 18:21:32 +0000 (Tue, 02 Nov 2010)
Log Message:
-----------
modules/dialog: Enhance unref_dlg_from_cb() robustness.
- Check parameter for NULL pointer.
- Call unreference_dlg(), thus being more wrapper-ish.
- Fix indention.
Backport from git commit 75fc49f74d13774f1ecc0cdd8f0adfe168915b4f.
Modified Paths:
--------------
branches/1.5/modules/dialog/dlg_handlers.c
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
Revision: 6048
http://openser.svn.sourceforge.net/openser/?rev=6048&view=rev
Author: mariuszbihlei
Date: 2010-11-02 09:40:31 +0000 (Tue, 02 Nov 2010)
Log Message:
-----------
trie API Fixed dtrie_insert OOM handling, where assert() was wrongfully used
Now the function behaves as expected, freeing previous allocated resources, logging the OOM condition , and returning -1
Modified Paths:
--------------
branches/1.5/trie/dtrie.c
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.