summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--net/asterisk12/Makefile1
-rw-r--r--net/asterisk12/files/patch-channel.c13
2 files changed, 14 insertions, 0 deletions
diff --git a/net/asterisk12/Makefile b/net/asterisk12/Makefile
index f4a07ae31c5f..4f1db3311d70 100644
--- a/net/asterisk12/Makefile
+++ b/net/asterisk12/Makefile
@@ -7,6 +7,7 @@
PORTNAME= asterisk
PORTVERSION= 1.2.17
+PORTREVISION= 1
PKGNAMESUFFIX= 12
CATEGORIES= net
MASTER_SITES= http://ftp.digium.com/pub/asterisk/ \
diff --git a/net/asterisk12/files/patch-channel.c b/net/asterisk12/files/patch-channel.c
index 8b3c313ad9d5..1c2e60452e2a 100644
--- a/net/asterisk12/files/patch-channel.c
+++ b/net/asterisk12/files/patch-channel.c
@@ -12,3 +12,16 @@ $FreeBSD$
#endif /* __linux__ */
#ifndef ZT_TIMERPING
#error "You need newer zaptel! Please svn update zaptel"
+@@ -1564,6 +1564,12 @@
+ if (!havewhen)
+ time(&now);
+ diff = c[x]->whentohangup - now;
++ if (diff < 1) {
++ /* Should already be hungup */
++ c[x]->_softhangup |= AST_SOFTHANGUP_TIMEOUT;
++ ast_mutex_unlock(&c[x]->lock);
++ return c[x];
++ }
+ if (!havewhen || (diff < whentohangup)) {
+ havewhen++;
+ whentohangup = diff;