[asterisk-commits] seanbright: branch seanbright/res-jabber-astobj2 r115574 - in /team/seanbrigh...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu May 8 19:16:27 CDT 2008


Author: seanbright
Date: Thu May  8 19:16:26 2008
New Revision: 115574

URL: http://svn.digium.com/view/asterisk?view=rev&rev=115574
Log:
Merged revisions 115507,115509,115513,115515,115518-115519,115521,115523,115525,115535,115537,115546,115548,115552,115555,115558,115562,115566,115569 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

................
r115507 | file | 2008-05-07 09:41:25 -0400 (Wed, 07 May 2008) | 4 lines

Remove redundant header getting.
(closes issue #12597)
Reported by: hooi

................
r115509 | tilghman | 2008-05-07 09:49:15 -0400 (Wed, 07 May 2008) | 6 lines

Update typos in description fields
(closes issue #12598)
 Reported by: suretec
 Patches: 
       asterisk_schema_changes.patch uploaded by suretec (license 70)

................
r115513 | russell | 2008-05-07 13:28:19 -0400 (Wed, 07 May 2008) | 19 lines

Merged revisions 115512 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r115512 | russell | 2008-05-07 11:24:09 -0500 (Wed, 07 May 2008) | 11 lines

Merged revisions 115511 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r115511 | russell | 2008-05-07 11:22:49 -0500 (Wed, 07 May 2008) | 3 lines

Remove remnants of dlinkedlists.  I didn't actually use them in the final version
of my IAX2 improvements.

........

................

................
r115515 | russell | 2008-05-07 13:38:36 -0400 (Wed, 07 May 2008) | 2 lines

re-add dlinkedlists.h to trunk, oops!

................
r115518 | russell | 2008-05-07 14:17:43 -0400 (Wed, 07 May 2008) | 12 lines

Blocked revisions 115517 via svnmerge

........
r115517 | russell | 2008-05-07 13:17:19 -0500 (Wed, 07 May 2008) | 5 lines

Track peer references when stored in the sip_pvt struct as the peer related to
a qualify ping or a subscription.  This fixes some realtime related crashes.
(closes issue #12588)
(closes issue #12555)

........

................
r115519 | russell | 2008-05-07 14:24:51 -0400 (Wed, 07 May 2008) | 2 lines

Let chan_h323 build in dev mode

................
r115521 | russell | 2008-05-07 14:30:12 -0400 (Wed, 07 May 2008) | 7 lines

Use the default that the log output claims will be used for the basedn

(closes issue #12599)
Reported by: suretec
Patches:
      12599.patch uploaded by juggie (license 24)

................
r115523 | russell | 2008-05-07 14:33:50 -0400 (Wed, 07 May 2008) | 6 lines

Only save a password if a username exists.

(closes issue #12600)
Reported By: suretec
Patch by me

................
r115525 | tilghman | 2008-05-07 14:40:21 -0400 (Wed, 07 May 2008) | 2 lines

Don't free the object on destroy, as astobj2 takes care of that for you

................
r115535 | tilghman | 2008-05-07 16:22:09 -0400 (Wed, 07 May 2008) | 2 lines

Advance to next sounds release

................
r115537 | russell | 2008-05-07 17:11:33 -0400 (Wed, 07 May 2008) | 10 lines

Fix up a problem that was introduced into the scheduler when it was converted
to use doubly linked lists.  The schedule() function had an optimization that
had it try to guess which direction would be better for the traversal to insert
the task into the scheduler queue.  However, if the code chose the path where
it traversed the queue in reverse, and the result was that the task should be
at the head of the queue, then the code would actually put it at the tail,
instead.

(Problem found by bbryant, debugged and fixed by bbryant and me)

................
r115546 | russell | 2008-05-08 10:41:12 -0400 (Thu, 08 May 2008) | 12 lines

Merged revisions 115545 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r115545 | russell | 2008-05-08 09:40:53 -0500 (Thu, 08 May 2008) | 4 lines

Use the same method for executing Asterisk as the rest of the script.
(closes issue #12611)
Reported by: b_plessis

........

................
r115548 | mattf | 2008-05-08 11:04:45 -0400 (Thu, 08 May 2008) | 1 line

Remove unused code as well as demote an error message to a debug message
................
r115552 | russell | 2008-05-08 11:26:49 -0400 (Thu, 08 May 2008) | 12 lines

Merged revisions 115551 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r115551 | russell | 2008-05-08 10:24:54 -0500 (Thu, 08 May 2008) | 4 lines

Don't use a channel before checking for channel allocation failure.
(closes issue #12609)
Reported by: edantie

........

................
r115555 | russell | 2008-05-08 11:32:48 -0400 (Thu, 08 May 2008) | 11 lines

Merged revisions 115554 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r115554 | russell | 2008-05-08 10:32:08 -0500 (Thu, 08 May 2008) | 3 lines

Don't exit the script if Asterisk is not running.
(closes issue #12611)

........

................
r115558 | russell | 2008-05-08 11:38:27 -0400 (Thu, 08 May 2008) | 11 lines

Merged revisions 115557 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r115557 | russell | 2008-05-08 10:37:49 -0500 (Thu, 08 May 2008) | 3 lines

remove postgres_cdr.sql, as the CDR schema is in realtime_pgsql.sql, as well
(closes issue #9676)

........

................
r115562 | russell | 2008-05-08 12:14:08 -0400 (Thu, 08 May 2008) | 11 lines

Merged revisions 115561 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r115561 | russell | 2008-05-08 11:11:33 -0500 (Thu, 08 May 2008) | 3 lines

Don't give up on attempting an outbound registration if we receive a 408 Timeout.
(closes issue #12323)

........

................
r115566 | russell | 2008-05-08 15:17:04 -0400 (Thu, 08 May 2008) | 41 lines

Merged revisions 115565 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r115565 | russell | 2008-05-08 14:15:25 -0500 (Thu, 08 May 2008) | 33 lines

Merged revisions 115564 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r115564 | russell | 2008-05-08 14:14:04 -0500 (Thu, 08 May 2008) | 25 lines

Fix a race condition that bbryant just found while doing some IAX2 testing.
He was running Asterisk trunk running IAX2 calls through a few Asterisk boxes,
however, the audio was extremely choppy.  We looked at a packet trace and saw
a storm of INVAL and VNAK frames being sent from one box to another.

It turned out that what had happened was that one box tried to send a CONTROL
frame before the 3 way handshake had completed.  So, that frame did not include
the destination call number, because it didn't have it yet.  Part of our recent
work for security issues included an additional check to ensure that frames that
are supposed to include the destination call number have the correct one.  This
caused the frame to be rejected with an INVAL.  The frame would get retransmitted
for forever, rejected every time ...

This race condition exists in all versions that got the security changes,
in theory.  However, it is really only likely that this would cause a problem in
Asterisk trunk.  There was a control frame being sent (SRCUPDATE) at the _very_
beginning of the call, which does not exist in 1.2 or 1.4.  However, I am fixing
all versions that could potentially be affected by the introduced race condition.

These changes are what bbryant and I came up with to fix the issue.  Instead of
simply dropping control frames that get sent before the handshake is complete,
the code attempts to wait a little while, since in most cases, the handshake
will complete very quickly.  If it doesn't complete after yielding for a little
while, then the frame gets dropped.

........

................

................
r115569 | russell | 2008-05-08 15:20:35 -0400 (Thu, 08 May 2008) | 10 lines

Merged revisions 115568 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r115568 | russell | 2008-05-08 14:19:50 -0500 (Thu, 08 May 2008) | 2 lines

Remove debug output.

........

................

Removed:
    team/seanbright/res-jabber-astobj2/contrib/scripts/postgres_cdr.sql
Modified:
    team/seanbright/res-jabber-astobj2/   (props changed)
    team/seanbright/res-jabber-astobj2/channels/chan_h323.c
    team/seanbright/res-jabber-astobj2/channels/chan_iax2.c
    team/seanbright/res-jabber-astobj2/channels/chan_sip.c
    team/seanbright/res-jabber-astobj2/channels/chan_zap.c
    team/seanbright/res-jabber-astobj2/contrib/init.d/rc.debian.asterisk
    team/seanbright/res-jabber-astobj2/contrib/scripts/asterisk.ldap-schema
    team/seanbright/res-jabber-astobj2/contrib/scripts/asterisk.ldif
    team/seanbright/res-jabber-astobj2/include/asterisk/dlinkedlists.h   (props changed)
    team/seanbright/res-jabber-astobj2/main/pbx.c
    team/seanbright/res-jabber-astobj2/main/sched.c
    team/seanbright/res-jabber-astobj2/res/res_config_ldap.c
    team/seanbright/res-jabber-astobj2/res/res_odbc.c
    team/seanbright/res-jabber-astobj2/sounds/Makefile

Propchange: team/seanbright/res-jabber-astobj2/
------------------------------------------------------------------------------
Binary property 'branch-1.4-blocked' - no diff available.

Propchange: team/seanbright/res-jabber-astobj2/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Propchange: team/seanbright/res-jabber-astobj2/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Thu May  8 19:16:26 2008
@@ -1,1 +1,1 @@
-/trunk:1-115499
+/trunk:1-115573

Modified: team/seanbright/res-jabber-astobj2/channels/chan_h323.c
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/channels/chan_h323.c?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/channels/chan_h323.c (original)
+++ team/seanbright/res-jabber-astobj2/channels/chan_h323.c Thu May  8 19:16:26 2008
@@ -1548,11 +1548,11 @@
 	struct oh323_peer *peer;
 	struct ast_variable *var;
 	struct ast_variable *tmp;
-	const char *addr;
+	const char *addr = NULL;
 
 	/* First check on peer name */
 	if (peername)
-		var = ast_load_realtime("h323", "name", peername, addr = NULL);
+		var = ast_load_realtime("h323", "name", peername, NULL);
 	else if (sin) /* Then check on IP address for dynamic peers */
 		var = ast_load_realtime("h323", "host", addr = ast_inet_ntoa(sin->sin_addr), NULL);
 	else

Modified: team/seanbright/res-jabber-astobj2/channels/chan_iax2.c
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/channels/chan_iax2.c?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/channels/chan_iax2.c (original)
+++ team/seanbright/res-jabber-astobj2/channels/chan_iax2.c Thu May  8 19:16:26 2008
@@ -87,7 +87,6 @@
 #include "asterisk/netsock.h"
 #include "asterisk/stringfields.h"
 #include "asterisk/linkedlists.h"
-#include "asterisk/dlinkedlists.h"
 #include "asterisk/event.h"
 #include "asterisk/astobj2.h"
 
@@ -640,8 +639,6 @@
 	int frames_dropped;
 	/*! received frame count: (just for stats) */
 	int frames_received;
-
-	AST_DLLIST_ENTRY(chan_iax2_pvt) entry;
 };
 
 /*!
@@ -3929,6 +3926,21 @@
 
 	ast_mutex_lock(&iaxsl[callno]);
 	pvt = iaxs[callno];
+
+	if (!pvt->peercallno) {
+		/* We don't know the remote side's call number, yet.  :( */
+		int count = 10;
+		while (count-- && pvt && !pvt->peercallno) {
+			ast_mutex_unlock(&iaxsl[callno]);
+			usleep(1);
+			ast_mutex_lock(&iaxsl[callno]);
+			pvt = iaxs[callno];
+		}
+		if (!pvt->peercallno) {
+			res = -1;
+			goto done;
+		}
+	}
 
 	switch (condition) {
 	case AST_CONTROL_HOLD:

Modified: team/seanbright/res-jabber-astobj2/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/channels/chan_sip.c?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/channels/chan_sip.c (original)
+++ team/seanbright/res-jabber-astobj2/channels/chan_sip.c Thu May  8 19:16:26 2008
@@ -6170,11 +6170,6 @@
 	const char *to = get_header(req, "To");
 	const char *cseq = get_header(req, "Cseq");
 	struct sip_pvt *sip_pvt_ptr;
-
-	callid = get_header(req, "Call-ID");
-	from = get_header(req, "From");
-	to = get_header(req, "To");
-	cseq = get_header(req, "Cseq");
 
 	/* Call-ID, to, from and Cseq are required by RFC 3261. (Max-forwards and via too - ignored now) */
 	/* get_header always returns non-NULL so we must use ast_strlen_zero() */
@@ -15975,8 +15970,6 @@
 		}
 		break;
 	case 408:	/* Request timeout */
-		if (global_regattempts_max)
-			p->registry->regattempts = global_regattempts_max+1;
 		p->needdestroy = 1;
 		if (r->call)
 			r->call = dialog_unref(r->call, "unsetting registry->call pointer-- case 408");

Modified: team/seanbright/res-jabber-astobj2/channels/chan_zap.c
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/channels/chan_zap.c?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/channels/chan_zap.c (original)
+++ team/seanbright/res-jabber-astobj2/channels/chan_zap.c Thu May  8 19:16:26 2008
@@ -9369,20 +9369,16 @@
 				res = ss7_read(ss7, pollers[i].fd);
 				ast_mutex_unlock(&linkset->lock);
 			}
+
 			if (pollers[i].revents & POLLOUT) {
 				ast_mutex_lock(&linkset->lock);
 				res = ss7_write(ss7, pollers[i].fd);
 				ast_mutex_unlock(&linkset->lock);
 				if (res < 0) {
-					ast_log(LOG_ERROR, "Error in write %s", strerror(errno));
-				}
-			}
-		}
-
-#if 0
-		if (res < 0)
-			exit(-1);
-#endif
+					ast_debug(1, "Error in write %s\n", strerror(errno));
+				}
+			}
+		}
 
 		while ((e = ss7_check_event(ss7))) {
 			switch (e->e) {

Modified: team/seanbright/res-jabber-astobj2/contrib/init.d/rc.debian.asterisk
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/contrib/init.d/rc.debian.asterisk?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/contrib/init.d/rc.debian.asterisk (original)
+++ team/seanbright/res-jabber-astobj2/contrib/init.d/rc.debian.asterisk Thu May  8 19:16:26 2008
@@ -22,6 +22,7 @@
 DESC="Asterisk PBX"
 # Full path to asterisk binary
 DAEMON=/usr/sbin/asterisk
+TRUE=/bin/true
 
 # Uncomment this ONLY if you know what you are doing.
 # export LD_ASSUME_KERNEL=2.4.1
@@ -53,7 +54,7 @@
   start)
 	# Check if Asterisk is already running.  If it is, then bug out, because
 	# starting up Asterisk when Asterisk is already running is very bad.
-	VERSION=`${ASTSBINDIR}/asterisk -rx 'core show version'`
+	VERSION=`${DAEMON} -rx 'core show version' || ${TRUE}`
 	if [ "${VERSION:0:8}" = "Asterisk" ]; then # otherwise "Unable t"
 		echo "Asterisk is already running.  $0 will exit now."
 		exit 1

Modified: team/seanbright/res-jabber-astobj2/contrib/scripts/asterisk.ldap-schema
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/contrib/scripts/asterisk.ldap-schema?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/contrib/scripts/asterisk.ldap-schema (original)
+++ team/seanbright/res-jabber-astobj2/contrib/scripts/asterisk.ldap-schema Thu May  8 19:16:26 2008
@@ -1,5 +1,12 @@
 #
-# Copyright (c) 2007 Suretec Systems Ltd. - <http://www.suretecsystems.com/>
+# Copyright (c) 2007-2008 Suretec Systems Ltd. - <http://www.suretecsystems.com/>
+#
+# Version: 3.1.5
+#
+# Changes:
+# - Fixed wrong DESC - 07/05/2008
+#
+# Author: Gavin Henry - <ghenry at suretecsystems.com>
 #
 # Asterisk LDAP Schema
 #
@@ -224,28 +231,28 @@
 
 attributetype ( AstAccountExpirationTimestamp 
         NAME 'AstAccountExpirationTimestamp'
-        DESC 'Asterisk Account Allowed Codec'
+        DESC 'Asterisk Account Expiration Timestamp'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 
 attributetype ( AstAccountRegistrationContext 
         NAME 'AstAccountRegistrationContext'
-        DESC 'Asterisk Account AMA Flags'
+        DESC 'Asterisk Account Registration Context'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 
 attributetype ( AstAccountRegistrationExten 
         NAME 'AstAccountRegistrationExten'
-        DESC 'Asterisk Account AMA Flags'
+        DESC 'Asterisk Account Registration Extension'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 
 attributetype ( AstAccountNoTransfer 
         NAME 'AstAccountNoTransfer'
-        DESC 'Asterisk Account AMA Flags'
+        DESC 'Asterisk Account No Transfer'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
@@ -327,28 +334,28 @@
       
 attributetype ( AstAccountRestrictCID 
         NAME 'AstAccountRestrictCID'
-        DESC 'Asterisk Restrict CallerID'
+        DESC 'Asterisk Account Restrict CallerID'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
             
 attributetype ( AstAccountRTPTimeout 
         NAME 'AstAccountRTPTimeout'
-        DESC 'Asterisk RTP Timeout'
+        DESC 'Asterisk Account RTP Timeout'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
       
 attributetype ( AstAccountRTPHoldTimeout 
         NAME 'AstAccountRTPHoldTimeout'
-        DESC 'Asterisk RTP Hold Timeout'
+        DESC 'Asterisk Account RTP Hold Timeout'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
       
 attributetype ( AstAccountRealmedPassword 
         NAME 'AstAccountRealmedPassword'
-        DESC 'Asterisk RTP Hold Timeout'
+        DESC 'Asterisk Account Realmed Password'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
@@ -362,21 +369,21 @@
 
 attributetype ( AstAccountMusicOnHold 
         NAME 'AstAccountMusicOnHold'
-        DESC 'Asterisk Account Allowed Codec'
+        DESC 'Asterisk Account Music On Hold'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 
 attributetype ( AstAccountCanCallForward 
         NAME 'AstAccountCanCallForward'
-        DESC 'Asterisk Can CAll Forward' 
+        DESC 'Asterisk Account Can Call Forward' 
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 
 attributetype ( AstAccountSecret 
         NAME 'AstAccountSecret'
-        DESC 'Asterisk Can CAll Forward' 
+        DESC 'Asterisk Account Secret' 
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
@@ -559,4 +566,3 @@
         AstConfigCommented
     ) 
     )
-

Modified: team/seanbright/res-jabber-astobj2/contrib/scripts/asterisk.ldif
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/contrib/scripts/asterisk.ldif?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/contrib/scripts/asterisk.ldif (original)
+++ team/seanbright/res-jabber-astobj2/contrib/scripts/asterisk.ldif Thu May  8 19:16:26 2008
@@ -1,5 +1,12 @@
 #
-# Copyright (c) 2007 Suretec Systems Ltd. - <http://www.suretecsystems.com/>
+# Copyright (c) 2007-2008 Suretec Systems Ltd. - <http://www.suretecsystems.com/>
+#
+# Version: 3.1.5
+#
+# Changes:
+# - Fixed wrong DESC - 07/05/2008
+#
+# Author: Gavin Henry - <ghenry at suretecsystems.com>
 #
 # Asterisk LDAP Schema ldif
 #
@@ -228,28 +235,28 @@
 #
 olcAttributeTypes: ( AstAccountExpirationTimestamp 
         NAME 'AstAccountExpirationTimestamp'
-        DESC 'Asterisk Account Allowed Codec'
+        DESC 'Asterisk Account Expiration Timestamp'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 #
 olcAttributeTypes: ( AstAccountRegistrationContext 
         NAME 'AstAccountRegistrationContext'
-        DESC 'Asterisk Account AMA Flags'
+        DESC 'Asterisk Account Registration Context'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 #
 olcAttributeTypes: ( AstAccountRegistrationExten 
         NAME 'AstAccountRegistrationExten'
-        DESC 'Asterisk Account AMA Flags'
+        DESC 'Asterisk Account Registration Extension'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 #
 olcAttributeTypes: ( AstAccountNoTransfer 
         NAME 'AstAccountNoTransfer'
-        DESC 'Asterisk Account AMA Flags'
+        DESC 'Asterisk Account No Transfer'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
@@ -331,28 +338,28 @@
 #      
 olcAttributeTypes: ( AstAccountRestrictCID 
         NAME 'AstAccountRestrictCID'
-        DESC 'Asterisk Restrict CallerID'
+        DESC 'Asterisk Account Restrict CallerID'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 #            
 olcAttributeTypes: ( AstAccountRTPTimeout 
         NAME 'AstAccountRTPTimeout'
-        DESC 'Asterisk RTP Timeout'
+        DESC 'Asterisk Account RTP Timeout'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 #      
 olcAttributeTypes: ( AstAccountRTPHoldTimeout 
         NAME 'AstAccountRTPHoldTimeout'
-        DESC 'Asterisk RTP Hold Timeout'
+        DESC 'Asterisk Account RTP Hold Timeout'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 #      
 olcAttributeTypes: ( AstAccountRealmedPassword 
         NAME 'AstAccountRealmedPassword'
-        DESC 'Asterisk RTP Hold Timeout'
+        DESC 'Asterisk Account Realmed Password'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
@@ -366,21 +373,21 @@
 #
 olcAttributeTypes: ( AstAccountMusicOnHold 
         NAME 'AstAccountMusicOnHold'
-        DESC 'Asterisk Account Allowed Codec'
+        DESC 'Asterisk Account Music On Hold'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 #
 olcAttributeTypes: ( AstAccountCanCallForward 
         NAME 'AstAccountCanCallForward'
-        DESC 'Asterisk Can CAll Forward' 
+        DESC 'Asterisk Account Can Call Forward' 
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
 #
 olcAttributeTypes: ( AstAccountSecret 
         NAME 'AstAccountSecret'
-        DESC 'Asterisk Can CAll Forward' 
+        DESC 'Asterisk Account Secret' 
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
@@ -564,4 +571,3 @@
     ) 
     )
 #
-

Propchange: team/seanbright/res-jabber-astobj2/include/asterisk/dlinkedlists.h
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Thu May  8 19:16:26 2008
@@ -1,1 +1,1 @@
-Author Id Date Revision
+Author Date Id Revision

Modified: team/seanbright/res-jabber-astobj2/main/pbx.c
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/main/pbx.c?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/main/pbx.c (original)
+++ team/seanbright/res-jabber-astobj2/main/pbx.c Thu May  8 19:16:26 2008
@@ -6310,13 +6310,13 @@
 		   the PBX, we have to make a new channel, masquerade, and start the PBX
 		   at the new location */
 		struct ast_channel *tmpchan = ast_channel_alloc(0, chan->_state, 0, 0, chan->accountcode, chan->exten, chan->context, chan->amaflags, "AsyncGoto/%s", chan->name);
-		if (chan->cdr) {
-			ast_cdr_discard(tmpchan->cdr);
-			tmpchan->cdr = ast_cdr_dup(chan->cdr);  /* share the love */
-		}
-		if (!tmpchan)
+		if (!tmpchan) {
 			res = -1;
-		else {
+		} else {
+			if (chan->cdr) {
+				ast_cdr_discard(tmpchan->cdr);
+				tmpchan->cdr = ast_cdr_dup(chan->cdr);  /* share the love */
+			}
 			/* Make formats okay */
 			tmpchan->readformat = chan->readformat;
 			tmpchan->writeformat = chan->writeformat;

Modified: team/seanbright/res-jabber-astobj2/main/sched.c
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/main/sched.c?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/main/sched.c (original)
+++ team/seanbright/res-jabber-astobj2/main/sched.c Thu May  8 19:16:26 2008
@@ -198,34 +198,45 @@
 	int de = 0;
 	struct sched *first = AST_DLLIST_FIRST(&con->schedq);
 	struct sched *last = AST_DLLIST_LAST(&con->schedq);
+
 	if (first)
 		df = ast_tvdiff_us(s->when, first->when);
 	if (last)
 		de = ast_tvdiff_us(s->when, last->when);
+
 	if (df < 0)
 		df = -df;
 	if (de < 0)
 		de = -de;
-	if (df < de)
+
+	if (df < de) {
 		AST_DLLIST_TRAVERSE(&con->schedq, cur, list) {
 			if (ast_tvcmp(s->when, cur->when) == -1) {
 				AST_DLLIST_INSERT_BEFORE(&con->schedq, cur, s, list);
 				break;
 			}
 		}
-	else
+		if (!cur) {
+			AST_DLLIST_INSERT_TAIL(&con->schedq, s, list);
+		}
+	} else {
 		AST_DLLIST_TRAVERSE_BACKWARDS(&con->schedq, cur, list) {
 			if (ast_tvcmp(s->when, cur->when) == 1) {
 				AST_DLLIST_INSERT_AFTER(&con->schedq, cur, s, list);
 				break;
 			}
 		}
-	if (!cur)
-		AST_DLLIST_INSERT_TAIL(&con->schedq, s, list);
+		if (!cur) {
+			AST_DLLIST_INSERT_HEAD(&con->schedq, s, list);
+		}
+	}
+
 	ret = ast_hashtab_insert_safe(con->schedq_ht, s);
 	if (!ret)
 		ast_log(LOG_WARNING,"Schedule Queue entry %d is already in table!\n",s->id);
+
 	con->schedcnt++;
+
 	if (con->schedcnt > con->highwater)
 		con->highwater = con->schedcnt;
 }

Modified: team/seanbright/res-jabber-astobj2/res/res_config_ldap.c
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/res/res_config_ldap.c?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/res/res_config_ldap.c (original)
+++ team/seanbright/res-jabber-astobj2/res/res_config_ldap.c Thu May  8 19:16:26 2008
@@ -58,6 +58,7 @@
 #include "asterisk/linkedlists.h"
 
 #define RES_CONFIG_LDAP_CONF "res_ldap.conf"
+#define RES_CONFIG_LDAP_DEFAULT_BASEDN "asterisk"
 
 AST_MUTEX_DEFINE_STATIC(ldap_lock);
 
@@ -1400,11 +1401,14 @@
 	} else 
 		ast_copy_string(user, s, sizeof(user));
 
-	if (!(s = ast_variable_retrieve(config, "_general", "pass"))) {
-		ast_log(LOG_WARNING, "No directory password found, using 'asterisk' as default.\n");
-		ast_copy_string(pass, "asterisk", sizeof(pass) - 1);
-	} else
-		ast_copy_string(pass, s, sizeof(pass));
+	if (!ast_strlen_zero(user)) {
+		if (!(s = ast_variable_retrieve(config, "_general", "pass"))) {
+			ast_log(LOG_WARNING, "No directory password found, using 'asterisk' as default.\n");
+			ast_copy_string(pass, "asterisk", sizeof(pass));
+		} else {
+			ast_copy_string(pass, s, sizeof(pass));
+		}
+	}
 
 	/* URL is preferred, use host and port if not found */
 	if ((s = ast_variable_retrieve(config, "_general", "url"))) {
@@ -1423,8 +1427,8 @@
 	}
 
 	if (!(s = ast_variable_retrieve(config, "_general", "basedn"))) {
-		ast_log(LOG_ERROR, "No LDAP base dn found, using 'asterisk' as default.\n");
-		basedn[0] = '\0';
+		ast_log(LOG_ERROR, "No LDAP base dn found, using '%s' as default.\n", RES_CONFIG_LDAP_DEFAULT_BASEDN);
+		ast_copy_string(basedn, RES_CONFIG_LDAP_DEFAULT_BASEDN, sizeof(basedn));
 	} else 
 		ast_copy_string(basedn, s, sizeof(basedn));
 

Modified: team/seanbright/res-jabber-astobj2/res/res_odbc.c
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/res/res_odbc.c?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/res/res_odbc.c (original)
+++ team/seanbright/res-jabber-astobj2/res/res_odbc.c Thu May  8 19:16:26 2008
@@ -100,7 +100,6 @@
 	odbc_obj_disconnect(obj);
 	ast_mutex_destroy(&obj->lock);
 	ao2_ref(obj->parent, -1);
-	ast_free(obj);
 }
 
 SQLHSTMT ast_odbc_direct_execute(struct odbc_obj *obj, SQLHSTMT (*exec_cb)(struct odbc_obj *obj, void *data), void *data)

Modified: team/seanbright/res-jabber-astobj2/sounds/Makefile
URL: http://svn.digium.com/view/asterisk/team/seanbright/res-jabber-astobj2/sounds/Makefile?view=diff&rev=115574&r1=115573&r2=115574
==============================================================================
--- team/seanbright/res-jabber-astobj2/sounds/Makefile (original)
+++ team/seanbright/res-jabber-astobj2/sounds/Makefile Thu May  8 19:16:26 2008
@@ -17,7 +17,7 @@
 
 SOUNDS_DIR:=$(DESTDIR)$(ASTDATADIR)/sounds
 MOH_DIR:=$(DESTDIR)$(ASTDATADIR)/moh
-CORE_SOUNDS_VERSION:=1.4.11
+CORE_SOUNDS_VERSION:=1.4.12
 EXTRA_SOUNDS_VERSION:=1.4.7
 SOUNDS_URL:=http://downloads.digium.com/pub/telephony/sounds/releases
 MCS:=$(subst -EN-,-en-,$(MENUSELECT_CORE_SOUNDS))




More information about the asterisk-commits mailing list