[svn-commits] trunk r31409 - /trunk/channels/misdn/isdn_lib.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Thu Jun 1 09:25:04 MST 2006


Author: crichter
Date: Thu Jun  1 11:25:04 2006
New Revision: 31409

URL: http://svn.digium.com/view/asterisk?rev=31409&view=rev
Log:
unified the PH_CONTROL Interface for the mISDN_dsp interface to int

Modified:
    trunk/channels/misdn/isdn_lib.c

Modified: trunk/channels/misdn/isdn_lib.c
URL: http://svn.digium.com/view/asterisk/trunk/channels/misdn/isdn_lib.c?rev=31409&r1=31408&r2=31409&view=diff
==============================================================================
--- trunk/channels/misdn/isdn_lib.c (original)
+++ trunk/channels/misdn/isdn_lib.c Thu Jun  1 11:25:04 2006
@@ -166,7 +166,7 @@
 void te_lib_destroy(int midev) ;
 struct misdn_bchannel *manager_find_bc_by_pid(int pid);
 struct misdn_bchannel *manager_find_bc_holded(struct misdn_bchannel* bc);
-void manager_ph_control_block(struct misdn_bchannel *bc, long c1, void *c2, int c2_len);
+void manager_ph_control_block(struct misdn_bchannel *bc, int c1, void *c2, int c2_len);
 void manager_clean_bc(struct misdn_bchannel *bc );
 void manager_bchannel_setup (struct misdn_bchannel *bc);
 void manager_bchannel_cleanup (struct misdn_bchannel *bc);
@@ -3677,17 +3677,17 @@
 /*
  * send control information to the channel (dsp-module)
  */
-void manager_ph_control(struct misdn_bchannel *bc, long c1, long c2)
-{
-	unsigned char buffer[mISDN_HEADER_LEN+2*sizeof(long)];
+void manager_ph_control(struct misdn_bchannel *bc, int c1, int c2)
+{
+	unsigned char buffer[mISDN_HEADER_LEN+2*sizeof(int)];
 	iframe_t *ctrl = (iframe_t *)buffer; /* preload data */
-	unsigned long *d = (unsigned long *)&ctrl->data.p;
+	unsigned int *d = (unsigned int*)&ctrl->data.p;
 	struct misdn_stack *stack=get_stack_by_bc(bc);
 	
 	ctrl->prim = PH_CONTROL | REQUEST;
 	ctrl->addr = bc->addr | FLG_MSG_DOWN;
 	ctrl->dinfo = 0;
-	ctrl->len = sizeof(unsigned long)*2;
+	ctrl->len = sizeof(unsigned int)*2;
 	*d++ = c1;
 	*d++ = c2;
 	mISDN_write(stack->midev, ctrl, mISDN_HEADER_LEN+ctrl->len, TIMEOUT_1SEC);
@@ -3696,17 +3696,17 @@
 /*
  * send control information to the channel (dsp-module)
  */
-void manager_ph_control_block(struct misdn_bchannel *bc, long c1, void *c2, int c2_len)
-{
-	unsigned char buffer[mISDN_HEADER_LEN+sizeof(long)+c2_len];
+void manager_ph_control_block(struct misdn_bchannel *bc, int c1, void *c2, int c2_len)
+{
+	unsigned char buffer[mISDN_HEADER_LEN+sizeof(int)+c2_len];
 	iframe_t *ctrl = (iframe_t *)buffer;
-	unsigned long *d = (unsigned long *)&ctrl->data.p;
+	unsigned int *d = (unsigned int *)&ctrl->data.p;
 	struct misdn_stack *stack=get_stack_by_bc(bc);
 	
 	ctrl->prim = PH_CONTROL | REQUEST;
 	ctrl->addr = bc->addr | FLG_MSG_DOWN;
 	ctrl->dinfo = 0;
-	ctrl->len = sizeof(unsigned long) + c2_len;
+	ctrl->len = sizeof(unsigned int) + c2_len;
 	*d++ = c1;
 	memcpy(d, c2, c2_len);
 	mISDN_write(stack->midev, ctrl, mISDN_HEADER_LEN+ctrl->len, TIMEOUT_1SEC);



More information about the svn-commits mailing list