[svn-commits] oej: branch oej/moremanager r63401 - in /team/oej/moremanager: ./ apps/ chann...

svn-commits at lists.digium.com svn-commits at lists.digium.com
Tue May 8 07:14:26 MST 2007


Author: oej
Date: Tue May  8 09:14:26 2007
New Revision: 63401

URL: http://svn.digium.com/view/asterisk?view=rev&rev=63401
Log:
Reset automerge

Added:
    team/oej/moremanager/configs/res_pgsql.conf.sample
      - copied unchanged from r63360, branches/1.4/configs/res_pgsql.conf.sample
    team/oej/moremanager/contrib/realtime_pgsql.sql
      - copied unchanged from r63360, branches/1.4/contrib/realtime_pgsql.sql
Modified:
    team/oej/moremanager/   (props changed)
    team/oej/moremanager/apps/app_voicemail.c
    team/oej/moremanager/channels/chan_sip.c
    team/oej/moremanager/configs/extconfig.conf.sample
    team/oej/moremanager/include/asterisk/app.h
    team/oej/moremanager/main/app.c
    team/oej/moremanager/main/channel.c

Propchange: team/oej/moremanager/
------------------------------------------------------------------------------
    automerge = http://edvina.net/training/

Propchange: team/oej/moremanager/
------------------------------------------------------------------------------
Binary property 'branch-1.2-merged' - no diff available.

Propchange: team/oej/moremanager/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Tue May  8 09:14:26 2007
@@ -1,1 +1,1 @@
-/branches/1.4:1-63275
+/branches/1.4:1-63400

Modified: team/oej/moremanager/apps/app_voicemail.c
URL: http://svn.digium.com/view/asterisk/team/oej/moremanager/apps/app_voicemail.c?view=diff&rev=63401&r1=63400&r2=63401
==============================================================================
--- team/oej/moremanager/apps/app_voicemail.c (original)
+++ team/oej/moremanager/apps/app_voicemail.c Tue May  8 09:14:26 2007
@@ -6579,21 +6579,24 @@
 			}
 			break;
 		case '7':
-			vms.deleted[vms.curmsg] = !vms.deleted[vms.curmsg];
-			if (useadsi)
-				adsi_delete(chan, &vms);
-			if (vms.deleted[vms.curmsg]) 
-				cmd = ast_play_and_wait(chan, "vm-deleted");
-			else
-				cmd = ast_play_and_wait(chan, "vm-undeleted");
-			if (ast_test_flag((&globalflags), VM_SKIPAFTERCMD)) {
-				if (vms.curmsg < vms.lastmsg) {
-					vms.curmsg++;
-					cmd = play_message(chan, vmu, &vms);
-				} else {
-					cmd = ast_play_and_wait(chan, "vm-nomore");
+			if (vms.curmsg >= 0 && vms.curmsg <= vms.lastmsg) {
+				vms.deleted[vms.curmsg] = !vms.deleted[vms.curmsg];
+				if (useadsi)
+					adsi_delete(chan, &vms);
+				if (vms.deleted[vms.curmsg]) 
+					cmd = ast_play_and_wait(chan, "vm-deleted");
+				else
+					cmd = ast_play_and_wait(chan, "vm-undeleted");
+				if (ast_test_flag((&globalflags), VM_SKIPAFTERCMD)) {
+					if (vms.curmsg < vms.lastmsg) {
+						vms.curmsg++;
+						cmd = play_message(chan, vmu, &vms);
+					} else {
+						cmd = ast_play_and_wait(chan, "vm-nomore");
+					}
 				}
-			}
+			} else /* Delete not valid if we haven't selected a message */
+				cmd = 0;
 #ifdef IMAP_STORAGE
 			deleted = 1;
 #endif

Modified: team/oej/moremanager/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/team/oej/moremanager/channels/chan_sip.c?view=diff&rev=63401&r1=63400&r2=63401
==============================================================================
--- team/oej/moremanager/channels/chan_sip.c (original)
+++ team/oej/moremanager/channels/chan_sip.c Tue May  8 09:14:26 2007
@@ -5238,7 +5238,7 @@
 		ast_set_write_format(p->owner, p->owner->writeformat);
 	}
 	
-	if (sin.sin_addr.s_addr && (!sendonly || sendonly == -1)) {
+	if (ast_test_flag(&p->flags[1], SIP_PAGE2_CALL_ONHOLD) && sin.sin_addr.s_addr && (!sendonly || sendonly == -1)) {
 		ast_queue_control(p->owner, AST_CONTROL_UNHOLD);
 		/* Activate a re-invite */
 		ast_queue_frame(p->owner, &ast_null_frame);
@@ -5254,19 +5254,17 @@
 	}
 
 	/* Manager Hold and Unhold events must be generated, if necessary */
-	if (sin.sin_addr.s_addr && (!sendonly || sendonly == -1)) {
-		if (ast_test_flag(&p->flags[1], SIP_PAGE2_CALL_ONHOLD)) {
-			append_history(p, "Unhold", "%s", req->data);
-			if (global_callevents)
-				manager_event(EVENT_FLAG_CALL, "Hold",
-					"HoldStatus: Off\r\n"
-					"Channel: %s\r\n"
-					"Uniqueid: %s\r\n",
-					p->owner->name, 
-					p->owner->uniqueid);
-			if (global_notifyhold)
-				sip_peer_hold(p, 0);
-		} 
+	if (ast_test_flag(&p->flags[1], SIP_PAGE2_CALL_ONHOLD) && sin.sin_addr.s_addr && (!sendonly || sendonly == -1)) {
+		append_history(p, "Unhold", "%s", req->data);
+		if (global_callevents)
+			manager_event(EVENT_FLAG_CALL, "Hold",
+				"HoldStatus: Off\r\n"
+				      "Channel: %s\r\n"
+				      "Uniqueid: %s\r\n",
+				      p->owner->name, 
+				      p->owner->uniqueid);
+		if (global_notifyhold)
+			sip_peer_hold(p, 0);
 		ast_clear_flag(&p->flags[1], SIP_PAGE2_CALL_ONHOLD);	/* Clear both flags */
 	} else if (!sin.sin_addr.s_addr || sendonly ) {
 		/* No address for RTP, we're on hold */

Modified: team/oej/moremanager/configs/extconfig.conf.sample
URL: http://svn.digium.com/view/asterisk/team/oej/moremanager/configs/extconfig.conf.sample?view=diff&rev=63401&r1=63400&r2=63401
==============================================================================
--- team/oej/moremanager/configs/extconfig.conf.sample (original)
+++ team/oej/moremanager/configs/extconfig.conf.sample Tue May  8 09:14:26 2007
@@ -40,7 +40,12 @@
 ; the family if the table is not specified
 ;
 ;example => odbc,asterisk,alttable
-;example2 => ldap,"dc=oxymium,dc=net",example2
+;
+; "odbc" is shown in the examples below, but is not the only valid realtime
+; engine.  There is:
+;    odbc ... res_config_odbc
+;    pgsql ... res_config_pgsql
+;    mysql ... res_config_mysql (available from asterisk-addons)
 ;
 ;iaxusers => odbc,asterisk
 ;iaxpeers => odbc,asterisk

Modified: team/oej/moremanager/include/asterisk/app.h
URL: http://svn.digium.com/view/asterisk/team/oej/moremanager/include/asterisk/app.h?view=diff&rev=63401&r1=63400&r2=63401
==============================================================================
--- team/oej/moremanager/include/asterisk/app.h (original)
+++ team/oej/moremanager/include/asterisk/app.h Tue May  8 09:14:26 2007
@@ -225,6 +225,9 @@
 /*! Discard all group counting for a channel */
 int ast_app_group_discard(struct ast_channel *chan);
 
+/*! Update all group counting for a channel to a new one */
+int ast_app_group_update(struct ast_channel *old, struct ast_channel *new);
+
 /*! Lock the group count list */
 int ast_app_group_list_lock(void);
 

Modified: team/oej/moremanager/main/app.c
URL: http://svn.digium.com/view/asterisk/team/oej/moremanager/main/app.c?view=diff&rev=63401&r1=63400&r2=63401
==============================================================================
--- team/oej/moremanager/main/app.c (original)
+++ team/oej/moremanager/main/app.c Tue May  8 09:14:26 2007
@@ -870,6 +870,20 @@
 	regfree(&regexbuf);
 
 	return count;
+}
+
+int ast_app_group_update(struct ast_channel *old, struct ast_channel *new)
+{
+	struct ast_group_info *gi = NULL;
+
+	AST_LIST_LOCK(&groups);
+	AST_LIST_TRAVERSE(&groups, gi, list) {
+		if (gi->chan == old)
+			gi->chan = new;
+	}
+	AST_LIST_UNLOCK(&groups);
+
+	return 0;
 }
 
 int ast_app_group_discard(struct ast_channel *chan)

Modified: team/oej/moremanager/main/channel.c
URL: http://svn.digium.com/view/asterisk/team/oej/moremanager/main/channel.c?view=diff&rev=63401&r1=63400&r2=63401
==============================================================================
--- team/oej/moremanager/main/channel.c (original)
+++ team/oej/moremanager/main/channel.c Tue May  8 09:14:26 2007
@@ -3616,7 +3616,7 @@
 			original->fds[x] = clone->fds[x];
 	}
 
-	ast_app_group_discard(original);
+	ast_app_group_update(clone, original);
 
 	/* move any whisperer over */
 	ast_channel_whisper_stop(original);



More information about the svn-commits mailing list