[libpri-commits] rmudgett: branch group/issue14068 r891 - /team/group/issue14068/

SVN commits to the libpri project libpri-commits at lists.digium.com
Wed Jun 24 13:37:45 CDT 2009


Author: rmudgett
Date: Wed Jun 24 13:37:41 2009
New Revision: 891

URL: http://svn.asterisk.org/svn-view/libpri?view=rev&rev=891
Log:
Resolve conflict and restart automerge

Merged revisions 885 via svnmerge from 
https://origsvn.digium.com/svn/libpri/branches/1.4

........
  r885 | seanbright | 2009-06-24 13:19:24 -0500 (Wed, 24 Jun 2009) | 10 lines
  
  Capture and expose the Reverse Charging Indication IE on ISDN PRI.
  
  (issue #13760)
  Reported by: mrgabu
  Patches:
        20090619_libpri_1.4.patch uploaded by seanbright (license 71)
  Tested by: seanbright, pruonckk
  
  Review: https://reviewboard.asterisk.org/r/291/
........

Modified:
    team/group/issue14068/   (props changed)
    team/group/issue14068/libpri.h
    team/group/issue14068/pri_internal.h
    team/group/issue14068/q931.c

Propchange: team/group/issue14068/
------------------------------------------------------------------------------
    automerge = *

Propchange: team/group/issue14068/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Wed Jun 24 13:37:41 2009
@@ -1,1 +1,1 @@
-/branches/1.4:1-880
+/branches/1.4:1-890

Modified: team/group/issue14068/libpri.h
URL: http://svn.asterisk.org/svn-view/libpri/team/group/issue14068/libpri.h?view=diff&rev=891&r1=890&r2=891
==============================================================================
--- team/group/issue14068/libpri.h (original)
+++ team/group/issue14068/libpri.h Wed Jun 24 13:37:41 2009
@@ -550,6 +550,7 @@
 	char origcallednum[256];
 	int callingplanorigcalled;		/* Dialing plan of Originally Called Number */
 	int origredirectingreason;
+	int reversecharge;
 	struct pri_subcommands *subcmds;
 } pri_event_ring;
 
@@ -859,6 +860,7 @@
 #define PRI_REDIRECTING_REASON
 #define PRI_AOC_UNITS
 #define PRI_ANI
+#define PRI_REVERSECHARGE_SUPPORT
 
 /* Send notification */
 int pri_notify(struct pri *pri, q931_call *c, int channel, int info);

Modified: team/group/issue14068/pri_internal.h
URL: http://svn.asterisk.org/svn-view/libpri/team/group/issue14068/pri_internal.h?view=diff&rev=891&r1=890&r2=891
==============================================================================
--- team/group/issue14068/pri_internal.h (original)
+++ team/group/issue14068/pri_internal.h Wed Jun 24 13:37:41 2009
@@ -423,6 +423,7 @@
 	q931_call *bridged_call;        /* Pointer to other leg of bridged call (Used by Q.SIG when eliminating tromboned calls) */
 
 	int changestatus;		/* SERVICE message changestatus */
+	int reversecharge;		/* Reverse charging indication */
 };
 
 extern int pri_schedule_event(struct pri *pri, int ms, void (*function)(void *data), void *data);

Modified: team/group/issue14068/q931.c
URL: http://svn.asterisk.org/svn-view/libpri/team/group/issue14068/q931.c?view=diff&rev=891&r1=890&r2=891
==============================================================================
--- team/group/issue14068/q931.c (original)
+++ team/group/issue14068/q931.c Wed Jun 24 13:37:41 2009
@@ -2632,6 +2632,16 @@
 	pri_message(ctrl, "Count=%d (0x%02x)\n", ie->data[0] & 0x1f, ie->data[0] & 0x1f);
 }
 
+static void dump_reverse_charging_indication(int full_ie, struct pri *ctrl, q931_ie *ie, int len, char prefix)
+{
+	pri_message(ctrl, "%c Reverse Charging Indication (len=%02d): %d\n", prefix, len, ie->data[0] & 0x7);
+}
+
+static int receive_reverse_charging_indication(int full_ie, struct pri *ctrl, q931_call *call, int msgtype, q931_ie *ie, int len)
+{
+	call->reversecharge = ie->data[0] & 0x7;
+	return 0;
+}
 
 static struct ie ies[] = {
 	/* Codeset 0 - Common */
@@ -2649,7 +2659,7 @@
 	{ 1, Q931_BINARY_PARAMETERS, "Packet-layer Binary Parameters" },
 	{ 1, Q931_WINDOW_SIZE, "Packet-layer Window Size" },
 	{ 1, Q931_CLOSED_USER_GROUP, "Closed User Group" },
-	{ 1, Q931_REVERSE_CHARGE_INDIC, "Reverse Charging Indication" },
+	{ 1, Q931_REVERSE_CHARGE_INDIC, "Reverse Charging Indication", dump_reverse_charging_indication, receive_reverse_charging_indication },
 	{ 1, Q931_CALLING_PARTY_NUMBER, "Calling Party Number", dump_calling_party_number, receive_calling_party_number, transmit_calling_party_number },
 	{ 1, Q931_CALLING_PARTY_SUBADDR, "Calling Party Subaddress", dump_calling_party_subaddr, receive_calling_party_subaddr },
 	{ 1, Q931_CALLED_PARTY_NUMBER, "Called Party Number", dump_called_party_number, receive_called_party_number, transmit_called_party_number },
@@ -4483,6 +4493,7 @@
 		ctrl->ev.ring.ctype = c->transcapability;
 		ctrl->ev.ring.progress = c->progress;
 		ctrl->ev.ring.progressmask = c->progressmask;
+		ctrl->ev.ring.reversecharge = c->reversecharge;
 
 		if (c->redirecting.count) {
 			subcmd = q931_alloc_subcommand(ctrl);




More information about the libpri-commits mailing list