diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/ChangeLog.beta wanpipe-3.1.4.6/ChangeLog.beta
--- r3145/wanpipe-3.1.4.5/ChangeLog.beta	2007-09-24 21:26:12.000000000 -0400
+++ wanpipe-3.1.4.6/ChangeLog.beta	2007-09-30 23:39:53.000000000 -0400
@@ -7,6 +7,12 @@
 Copyright (c) 1995-2007 Sangoma Technologies Inc.
 ------------------------------------------------------------------------------
 
+* Mon Oct 1 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.1.4.6
+==================================================================== 
+
+- Fixed Makefile for 2.6.22.9 kernel.
+- Fixed all gcc4 warnings.
+
 
 * Tue Sep 26 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.1.4.5
 ==================================================================== 
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/deb_control/wanpipe.deb wanpipe-3.1.4.6/deb_control/wanpipe.deb
--- r3145/wanpipe-3.1.4.5/deb_control/wanpipe.deb	2007-09-24 21:27:32.000000000 -0400
+++ wanpipe-3.1.4.6/deb_control/wanpipe.deb	2007-09-30 23:31:17.000000000 -0400
@@ -1,5 +1,5 @@
 Package: wanpipe
-Version: 3.1.4.5-0
+Version: 3.1.4.6-0
 Section: networking
 Priority: optional
 Architecture: all
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/patches/kdrivers/include/sdla_te1_ds.h wanpipe-3.1.4.6/patches/kdrivers/include/sdla_te1_ds.h
--- r3145/wanpipe-3.1.4.5/patches/kdrivers/include/sdla_te1_ds.h	2007-07-10 16:39:33.000000000 -0400
+++ wanpipe-3.1.4.6/patches/kdrivers/include/sdla_te1_ds.h	2007-09-28 14:28:30.000000000 -0400
@@ -489,6 +489,8 @@
 #define REG_TCICE3		0x152
 #define REG_TCICE4		0x153
 
+#define REG_T1TFDL		0x162
+
 #define REG_E1TAF		0x164
 
 #define REG_E1TNAF		0x165
@@ -518,7 +520,9 @@
 #define BIT_TCR1_E1_TCRC4	0x01
 
 #define REG_TCR2		0x182
-#define BIT_TCR2_TD4RM		0x04
+#define BIT_TCR2_T1_TD4RM	0x04
+#define BIT_TCR2_T1_TSLC96	0x40
+#define BIT_TCR2_T1_TFDLS	0x80
 #define BIT_TCR2_E1_AEBE	0x80
 
 #define REG_TCR3		0x183
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/patches/kdrivers/src/net/Makefile wanpipe-3.1.4.6/patches/kdrivers/src/net/Makefile
--- r3145/wanpipe-3.1.4.5/patches/kdrivers/src/net/Makefile	2007-03-07 15:06:13.000000000 -0500
+++ wanpipe-3.1.4.6/patches/kdrivers/src/net/Makefile	2007-09-28 21:29:26.000000000 -0400
@@ -75,7 +75,7 @@
 
 af_wanpipe-objs	:= ../wanrouter/af_wanpipe_src.o  ../wanrouter/af_wanpipe_datascope.o  
 
-wan_aften-objs := ../wan_aften/wan_aften_src.o wanpipe_linux_iface.o
+wan_aften-objs := ../wan_aften/wan_aften_src.o ../wan_aften/wanpipe_linux_iface.o
 
 obj-m += $(WAN_MODULES)      
 
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/patches/kdrivers/src/net/Module.symvers wanpipe-3.1.4.6/patches/kdrivers/src/net/Module.symvers
--- r3145/wanpipe-3.1.4.5/patches/kdrivers/src/net/Module.symvers	2007-09-13 12:49:24.000000000 -0400
+++ wanpipe-3.1.4.6/patches/kdrivers/src/net/Module.symvers	2007-09-28 21:36:19.000000000 -0400
@@ -1,22 +1,22 @@
 0xf7567a8a	wanpipe_api_buf_check	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0xf27fa082	wanpipe_lip_connect	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
-0xd597d7ea	sdla_register	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/sdladrv	EXPORT_SYMBOL
+0x3000ad78	sdla_register	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/sdladrv	EXPORT_SYMBOL
 0xc0ef42f1	wp_sppp_input	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanpipe_syncppp	EXPORT_SYMBOL
 0x57e6ed60	wanpipe_api_sock_rx	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
-0xc697649f	wanrouter_proc_add_interface	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
+0x5f97184e	wanrouter_proc_add_interface	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x59fb2682	sdla_hw_probe	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/sdladrv	EXPORT_SYMBOL
 0x9a7a6658	wanpipe_lip_rx	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x8f31cdeb	proc_router	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x94be524d	register_wanec_iface	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x1036a1ab	bind_api_listen_to_protocol	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x524e2f20	register_wanpipe_fw_protocol	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
-0xc6eb6c6d	register_wan_device	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
-0x8b5a9a31	wanrouter_proc_add_protocol	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
+0x457621b6	register_wan_device	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
+0xdad88768	wanrouter_proc_add_protocol	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0xc9b2c3fb	wp_sppp_attach	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanpipe_syncppp	EXPORT_SYMBOL
 0x90a9f616	wp_sppp_detach	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanpipe_syncppp	EXPORT_SYMBOL
 0x56712648	wanpipe_ec_event_ctrl	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x7cd3c2bc	wanpipe_ec_poll	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
-0xc6924976	wanrouter_proc_delete_protocol	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
+0xf35baa74	wanrouter_proc_delete_protocol	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0xdfd0f6c6	sdla_get_hw_adptr_cnt	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/sdladrv	EXPORT_SYMBOL
 0x10723cdb	wanpipe_ec_register	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x1e82f485	wp_sppp_change_mtu	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanpipe_syncppp	EXPORT_SYMBOL
@@ -46,7 +46,7 @@
 0x5b7efb57	wanpipe_api_poll_wake	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x651a840a	wan_add_gateway	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x805cbe1e	wp_sppp_close	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanpipe_syncppp	EXPORT_SYMBOL
-0x5f1809f9	wanrouter_proc_delete_interface	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
+0x29d0266f	wanrouter_proc_delete_interface	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x2f21a326	unregister_wanpipe_lip_protocol	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x0ebe03d1	unregister_wan_device	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
 0x22317d82	wanpipe_lip_disconnect	/hda5/wanpipe/3.1.X/wanpipe-3.1.0.p7/patches/kdrivers/src/net/wanrouter	EXPORT_SYMBOL
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/patches/kdrivers/src/net/sdla_8te1.c wanpipe-3.1.4.6/patches/kdrivers/src/net/sdla_8te1.c
--- r3145/wanpipe-3.1.4.5/patches/kdrivers/src/net/sdla_8te1.c	2007-07-10 16:38:51.000000000 -0400
+++ wanpipe-3.1.4.6/patches/kdrivers/src/net/sdla_8te1.c	2007-09-28 14:25:54.000000000 -0400
@@ -712,10 +712,15 @@
 	switch(WAN_FE_FRAME(fe)){
 	case WAN_FR_D4:
 		value = READ_REG(REG_RCR1);
-		WRITE_REG(REG_RCR1, value | BIT_RCR1_T1_RFM | BIT_RCR1_T1_SYNCC);
+		WRITE_REG(REG_RCR1, value | BIT_RCR1_T1_RFM/* | BIT_RCR1_T1_SYNCC*/);
 
+		value = READ_REG(REG_TCR2);
+		WRITE_REG(REG_TCR2, value & ~BIT_TCR2_T1_TFDLS);
+	
 		value = READ_REG(REG_TCR3);
 		WRITE_REG(REG_TCR3, value | BIT_TCR3_TFM);
+
+		WRITE_REG(REG_T1TFDL, 0x1c);
 		break;
 
 	case WAN_FR_ESF:
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/patches/kdrivers/src/net/sdla_remora_tdmv.c wanpipe-3.1.4.6/patches/kdrivers/src/net/sdla_remora_tdmv.c
--- r3145/wanpipe-3.1.4.5/patches/kdrivers/src/net/sdla_remora_tdmv.c	2007-04-24 19:14:40.000000000 -0400
+++ wanpipe-3.1.4.6/patches/kdrivers/src/net/sdla_remora_tdmv.c	2007-09-28 21:33:27.000000000 -0400
@@ -1076,7 +1076,6 @@
 
 	/* Initialize Callback event function pointers */	
 	if (wr->dtmfsupport == WANOPT_YES){
-		DEBUG_EVENT("ADBG> Updating event callback dtmf\n");
 		card->wandev.event_callback.dtmf = wp_tdmv_remora_dtmf;
 	}
 	return 0;
@@ -1682,7 +1681,7 @@
 	}
 					
 	if (!(wr->dtmfmask & (1 << (event->channel-1)))){
-		DEBUG_EVENT("ADBG> %s: DTMF is not enabled for the channel %d\n",
+		DEBUG_TEST("%s: DTMF is not enabled for the channel %d\n",
 					card->devname,
 					event->channel);
 		return;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/patches/kdrivers/src/net/sdla_tdmv.c wanpipe-3.1.4.6/patches/kdrivers/src/net/sdla_tdmv.c
--- r3145/wanpipe-3.1.4.5/patches/kdrivers/src/net/sdla_tdmv.c	2007-04-25 14:59:41.000000000 -0400
+++ wanpipe-3.1.4.6/patches/kdrivers/src/net/sdla_tdmv.c	2007-09-26 10:14:35.000000000 -0400
@@ -697,7 +697,6 @@
 	if (!(wp->chans[i].sig & ZT_SIG_CLEAR) &&
 	    (wp->chans[i].rxsig != rxs)){
 		zt_rbsbits(&wp->chans[i], rxs);
-#if 1
 		DEBUG_TDMV(
 		"[TDMV] %s: %s:%02d(%d) RX RBS: A:%1d B:%1d C:%1d D:%1d\n",
 				wp->devname, 
@@ -707,7 +706,6 @@
 				(rxs & ZT_BBIT) ? 1 : 0,
 				(rxs & ZT_CBIT) ? 1 : 0,
 				(rxs & ZT_DBIT) ? 1 : 0);
-#endif
 	}
 }
 
@@ -1521,8 +1519,7 @@
 	if (chan->flags & ZT_FLAG_HDLC){
 		return 0;
 	}
-#if 1
-	DEBUG_EVENT(
+	DEBUG_TDMV(
 	"[TDMV] %s: %s:%02d(%d) TX RBS: A:%1d B:%1d C:%1d D:%1d\n", 
 			wp->devname, 
 			(wp->ise1) ? "E1" : "T1",
@@ -1531,7 +1528,6 @@
 			(ABCD_bits & WAN_RBS_SIG_B) ? 1 : 0,
 			(ABCD_bits & WAN_RBS_SIG_C) ? 1 : 0,
 			(ABCD_bits & WAN_RBS_SIG_D) ? 1 : 0);
-#endif
 
 	if (wan_test_and_set_bit(chan->chanpos-1, &wp->rbs_tx_status)){
 		if (ABCD_bits == wp->rbs_tx[chan->chanpos-1]){
Binary files r3145/wanpipe-3.1.4.5/patches/kdrivers/src/wan_aften/wan_aften_src.o and wanpipe-3.1.4.6/patches/kdrivers/src/wan_aften/wan_aften_src.o differ
Only in wanpipe-3.1.4.6/patches/kdrivers/src/wan_aften: wanpipe_linux_iface.c
Only in wanpipe-3.1.4.6/patches/kdrivers/src/wan_aften: wanpipe_linux_iface.o
Binary files r3145/wanpipe-3.1.4.5/patches/kdrivers/src/wanrouter/af_wanpipe_datascope.o and wanpipe-3.1.4.6/patches/kdrivers/src/wanrouter/af_wanpipe_datascope.o differ
Binary files r3145/wanpipe-3.1.4.5/patches/kdrivers/src/wanrouter/af_wanpipe_src.o and wanpipe-3.1.4.6/patches/kdrivers/src/wanrouter/af_wanpipe_src.o differ
Binary files r3145/wanpipe-3.1.4.5/patches/kdrivers/src/wanrouter/waniface.o and wanpipe-3.1.4.6/patches/kdrivers/src/wanrouter/waniface.o differ
Binary files r3145/wanpipe-3.1.4.5/patches/kdrivers/src/wanrouter/wanmain.o and wanpipe-3.1.4.6/patches/kdrivers/src/wanrouter/wanmain.o differ
Binary files r3145/wanpipe-3.1.4.5/patches/kdrivers/src/wanrouter/wanproc.o and wanpipe-3.1.4.6/patches/kdrivers/src/wanrouter/wanproc.o differ
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/patches/kdrivers/wanec/.tmp_versions/wanec.mod wanpipe-3.1.4.6/patches/kdrivers/wanec/.tmp_versions/wanec.mod
--- r3145/wanpipe-3.1.4.5/patches/kdrivers/wanec/.tmp_versions/wanec.mod	2007-09-24 21:29:14.000000000 -0400
+++ wanpipe-3.1.4.6/patches/kdrivers/wanec/.tmp_versions/wanec.mod	2007-09-30 23:32:56.000000000 -0400
@@ -1,2 +1,2 @@
-/root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec.ko
-/root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec_iface.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec_cmd.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec_utils.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec_dev.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/apilib/bt/octapi_bt0.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/apilib/largmath/octapi_largmath.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/apilib/llman/octapi_llman.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_apimi/oct6100_mask_interrupts.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_adpcm_chan.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_channel.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_chip_open.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_chip_stats.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_conf_bridge.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_debug.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_events.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_interrupts.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_memory.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_miscellaneous.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_mixer.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_phasing_tsst.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_playout_buf.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_remote_debug.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_tlv.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_tone_detection.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_tsi_cnct.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_tsst.o /root/development/3.1/wanpipe-3.1.4.5/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_user.o
+/root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec.ko
+/root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec_iface.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec_cmd.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec_utils.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec_dev.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/apilib/bt/octapi_bt0.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/apilib/largmath/octapi_largmath.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/apilib/llman/octapi_llman.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_apimi/oct6100_mask_interrupts.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_adpcm_chan.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_channel.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_chip_open.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_chip_stats.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_conf_bridge.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_debug.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_events.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_interrupts.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_memory.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_miscellaneous.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_mixer.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_phasing_tsst.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_playout_buf.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_remote_debug.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_tlv.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_tone_detection.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_tsi_cnct.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_tsst.o /root/development/3.1/wanpipe-3.1.4.6/patches/kdrivers/wanec/oct6100_api/octdeviceapi/oct6100api/oct6100_api/oct6100_user.o
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec_cmd.c wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec_cmd.c
--- r3145/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec_cmd.c	2007-07-30 14:22:57.000000000 -0400
+++ wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec_cmd.c	2007-09-30 21:09:32.000000000 -0400
@@ -1348,7 +1348,7 @@
 		card = (sdla_t*)ec_dev->card;
 		if (card->wandev.event_callback.dtmf){
 			wan_event_t	event;
-			unsigned char	dtmf_port, dtmf_type;
+			unsigned char	dtmf_port=0, dtmf_type=0;
 			
 			event.type	= WAN_EVENT_EC_DTMF;
 			event.channel	= fe_chan;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec_iface.c wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec_iface.c
--- r3145/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec_iface.c	2007-07-16 14:05:47.000000000 -0400
+++ wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec_iface.c	2007-09-30 21:04:32.000000000 -0400
@@ -337,7 +337,7 @@
 		}
 	}else{
 		PRINT1(verbose, 
-		"%s: HWEC option is not enable for the channel %d (%lX)!\n",
+		"%s: HWEC option is not enabled for the channel %d (%lX)!\n",
 				ec->name, fe_channel, card->wandev.ec_enable_map);
 		return err;
 	}
@@ -973,7 +973,7 @@
 		switch(ec_api->cmd){
 		case WAN_EC_CMD_DTMF_ENABLE:
 			if (wanec_bypass(ec_dev, fe_chan, 1, ec_api->verbose)){
-				return WAN_EC_API_RC_FAILED;
+				continue;
 			}
 			err = wanec_TonesEnable(	
 					ec,
@@ -987,9 +987,8 @@
 					ec_channel,
 					ec_api->u_dtmf_config.port,
 					ec_api->verbose);
-			if (wanec_bypass(ec_dev, fe_chan, 0, ec_api->verbose)){
-				return WAN_EC_API_RC_FAILED;
-			}
+
+			/* Do not try to disable hwec */
 			break;
 		default:
 			err = WAN_EC_API_RC_INVALID_CMD;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec.mod.c wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec.mod.c
--- r3145/wanpipe-3.1.4.5/patches/kdrivers/wanec/wanec.mod.c	2007-09-18 14:13:50.000000000 -0400
+++ wanpipe-3.1.4.6/patches/kdrivers/wanec/wanec.mod.c	2007-09-30 23:32:56.000000000 -0400
@@ -51,4 +51,4 @@
 "depends=";
 
 
-MODULE_INFO(srcversion, "3F518EE5B16E643E85FE299");
+MODULE_INFO(srcversion, "2EFC0B2F3DABEB9146FC376");
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/rpmspec/wanpipe-mod.spec wanpipe-3.1.4.6/rpmspec/wanpipe-mod.spec
--- r3145/wanpipe-3.1.4.5/rpmspec/wanpipe-mod.spec	2007-09-24 22:07:38.000000000 -0400
+++ wanpipe-3.1.4.6/rpmspec/wanpipe-mod.spec	2007-09-30 23:39:59.000000000 -0400
@@ -1,6 +1,6 @@
 %define WANPIPE_VER	  wanpipe-modules
 %define name              %{WANPIPE_VER}
-%define version           3.1.4.5
+%define version           3.1.4.6
 %define release           0
 %define	serial	 	  1
 %define MODULES_DIR	  /lib/modules
@@ -50,6 +50,12 @@
 
 
 %changelog
+* Mon Oct 1 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.1.4.6
+==================================================================== 
+
+- Fixed Makefile for 2.6.22.9 kernel.
+- Fixed all gcc4 warnings.
+
 
 * Tue Sep 26 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.1.4.5
 ==================================================================== 
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/rpmspec/wanpipe.spec wanpipe-3.1.4.6/rpmspec/wanpipe.spec
--- r3145/wanpipe-3.1.4.5/rpmspec/wanpipe.spec	2007-09-24 22:07:38.000000000 -0400
+++ wanpipe-3.1.4.6/rpmspec/wanpipe.spec	2007-09-30 23:39:59.000000000 -0400
@@ -1,7 +1,7 @@
 %define KERNEL_VERSION    %{?kern_ver}
 %define WANPIPE_VER	  wanpipe
 %define name              %{WANPIPE_VER}
-%define version           3.1.4.5
+%define version           3.1.4.6
 %define release           0
 %define	serial	 	  1
 %define UTILS_DIR 	  /usr/sbin
@@ -172,6 +172,7 @@
 # ----------------------------------------------------------------------------
 # Install initialization scripts.
 # ----------------------------------------------------------------------------
+install_init()
 {
 	ln -s /usr/sbin/wanrouter /etc/init.d/wanrouter
 	chkconfig wanrouter on
@@ -252,6 +253,12 @@
 
 
 %changelog
+* Mon Oct 1 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.1.4.6
+==================================================================== 
+
+- Fixed Makefile for 2.6.22.9 kernel.
+- Fixed all gcc4 warnings.
+
 
 * Tue Sep 26 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.1.4.5
 ==================================================================== 
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/rpmspec/wanpipe-util.spec wanpipe-3.1.4.6/rpmspec/wanpipe-util.spec
--- r3145/wanpipe-3.1.4.5/rpmspec/wanpipe-util.spec	2007-09-24 22:07:38.000000000 -0400
+++ wanpipe-3.1.4.6/rpmspec/wanpipe-util.spec	2007-09-30 23:39:59.000000000 -0400
@@ -1,7 +1,7 @@
 %define KERNEL_VERSION    %{?kern_ver}
 %define WANPIPE_VER	  wanpipe-util
 %define name              %{WANPIPE_VER}
-%define version           3.1.4.5
+%define version           3.1.4.6
 %define release           0
 %define	serial	 	  1
 %define UTILS_DIR 	  /usr/sbin
@@ -244,6 +244,12 @@
 
 
 %changelog
+* Mon Oct 1 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.1.4.6
+==================================================================== 
+
+- Fixed Makefile for 2.6.22.9 kernel.
+- Fixed all gcc4 warnings.
+
 
 * Tue Sep 26 2007 Nenad Corbic <ncorbic@sangoma.com> - Beta - 3.1.4.5
 ==================================================================== 
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/samples/wanrouter wanpipe-3.1.4.6/samples/wanrouter
--- r3145/wanpipe-3.1.4.5/samples/wanrouter	2007-09-24 21:27:32.000000000 -0400
+++ wanpipe-3.1.4.6/samples/wanrouter	2007-09-30 23:31:17.000000000 -0400
@@ -2116,7 +2116,7 @@
 RUGGEDCOM=No
 
 if [ $OSYSTEM = "Linux" ]; then
-	ROUTER_VERSION=3.1.4.5
+	ROUTER_VERSION=3.1.4.6
 	IFCONFIG_LIST=ifconfig
 	MODULE_STAT=lsmod
 	WAN_DRIVERS="wanpipe"
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/Setup wanpipe-3.1.4.6/Setup
--- r3145/wanpipe-3.1.4.5/Setup	2007-09-24 21:32:05.000000000 -0400
+++ wanpipe-3.1.4.6/Setup	2007-09-30 23:31:17.000000000 -0400
@@ -6266,7 +6266,7 @@
 PKG_NAME=wanpipe
 DISTR_NAME="WANPIPE"
 PROD=wanrouter
-PROD_VER=3.1.4.5
+PROD_VER=3.1.4.6
 PROD_HOME=`pwd`
 META_CONF=$PROD_HOME/$PROD.rc
 WAN_INTR_DIR=$PROD_HOME/interfaces
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/lxdialog/dialog.h wanpipe-3.1.4.6/util/lxdialog/dialog.h
--- r3145/wanpipe-3.1.4.5/util/lxdialog/dialog.h	2007-02-09 12:49:20.000000000 -0500
+++ wanpipe-3.1.4.6/util/lxdialog/dialog.h	2007-09-30 21:47:33.000000000 -0400
@@ -171,7 +171,7 @@
 int dialog_checklist (const char *title, const char *prompt, int height,
 		int width, int list_height, int item_no,
 		const char * const * items, int flag);
-extern unsigned char dialog_input_result[];
+extern char dialog_input_result[];
 int dialog_inputbox (const char *title, const char *prompt, int height,
 		int width, const char *init);
 
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/lxdialog/inputbox.c wanpipe-3.1.4.6/util/lxdialog/inputbox.c
--- r3145/wanpipe-3.1.4.5/util/lxdialog/inputbox.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/lxdialog/inputbox.c	2007-09-30 21:47:21.000000000 -0400
@@ -21,7 +21,7 @@
 
 #include "dialog.h"
 
-unsigned char dialog_input_result[MAX_LEN + 1];
+char dialog_input_result[MAX_LEN + 1];
 
 /*
  *  Print the termination buttons
@@ -48,7 +48,7 @@
 {
     int i, x, y, box_y, box_x, box_width;
     int input_x = 0, scroll = 0, key = 0, button = -1;
-    unsigned char *instr = dialog_input_result;
+    char *instr = dialog_input_result;
     WINDOW *dialog;
 
     /* center dialog box on screen */
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/sdladump/sdladump.c wanpipe-3.1.4.6/util/sdladump/sdladump.c
--- r3145/wanpipe-3.1.4.5/util/sdladump/sdladump.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/sdladump/sdladump.c	2007-09-30 21:53:06.000000000 -0400
@@ -95,7 +95,7 @@
 int do_debug(int argc, char *argv[]);
 void show_dump	(char* buf, unsigned long len, unsigned long addr);
 void show_error	(int err);
-int hexdump	(char* str, unsigned char* data, int length, int limit);
+int hexdump	(char* str, char* data, int length, int limit);
 
 extern	int close (int);
 
@@ -343,7 +343,7 @@
  * Return number of bytes dumped.
  * NOTE: string buffer must be at least (limit * 4 + 2) bytes long.
  */
-int hexdump (char* str, unsigned char* data, int length, int limit)
+int hexdump (char* str, char* data, int length, int limit)
 {
 	int i, n;
 
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanconfig/wanconfig.c wanpipe-3.1.4.6/util/wanconfig/wanconfig.c
--- r3145/wanpipe-3.1.4.5/util/wanconfig/wanconfig.c	2007-07-18 11:36:46.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanconfig/wanconfig.c	2007-09-30 21:52:17.000000000 -0400
@@ -248,7 +248,7 @@
 int name2val (char* name, look_up_t* table);
 int read_data_file (char* name, data_buf_t* databuf);
 unsigned long filesize (FILE* file);
-unsigned int dec_to_uint (unsigned char* str, int len);
+unsigned int dec_to_uint (char* str, int len);
 unsigned int get_config_data (int, char**);
 void show_help(void);
 void show_usage(void);
@@ -300,7 +300,7 @@
 void sig_func (int sigio);
 int start_link (void);
 int stop_link(void);
-int exec_command(unsigned char *rx_data);
+int exec_command(char *rx_data);
 void catch_signal(int signum,int nomask);
 
 /****** Global Data *********************************************************/
@@ -319,7 +319,7 @@
 char banner[] =		"WAN Router Configurator"
 			"(c) 1995-2003 Sangoma Technologies Inc.";
 
-static unsigned char wan_version[100];
+static char wan_version[100];
 
 
 char usagetext[] = 
@@ -2993,7 +2993,7 @@
 
 #if defined(__LINUX__)
 	case ANNEXG_LAPB:
-		strncpy(def->chanconf->master,master_lapb_dev, WAN_IFNAME_SZ);
+		strncpy((char*)def->chanconf->master,master_lapb_dev, WAN_IFNAME_SZ);
 
 		if (ioctl(dev, ROUTER_IFNEW_LAPB, def->chanconf) < 0) {
 			fprintf(stderr, "\n\n\t%s: Interface %s setup failed\n", prognamed, def->name);
@@ -3011,7 +3011,7 @@
 		break;
 
 	case ANNEXG_X25:
-		strncpy(def->chanconf->master, master_x25_dev, WAN_IFNAME_SZ);
+		strncpy((char*)def->chanconf->master, master_x25_dev, WAN_IFNAME_SZ);
 
 		if (ioctl(dev, ROUTER_IFNEW_X25, def->chanconf) < 0) {
 			fprintf(stderr, "\n\n\t%s: Interface %s setup failed\n", prognamed, def->name);
@@ -3030,7 +3030,7 @@
 
 	// DSP_20
 	case ANNEXG_DSP:
-		strncpy(def->chanconf->master, master_dsp_dev, WAN_IFNAME_SZ);
+		strncpy((char*)def->chanconf->master, master_dsp_dev, WAN_IFNAME_SZ);
 		if (ioctl(dev, ROUTER_IFNEW_DSP, def->chanconf) < 0) {
 			fprintf(stderr, "\n\n\t%s: Interface %s setup failed\n", prognamed, def->name);
 			fprintf(stderr, "\t%s: ioctl(ROUTER_IFNEW_DSP,%s) failed:\n", 
@@ -3058,7 +3058,7 @@
 	case ANNEXG_LIP_X25:
 	case ANNEXG_LIP_ATM:
 	case ANNEXG_LIP_KATM:
-		strncpy(def->chanconf->master, master_lip_dev, WAN_IFNAME_SZ);
+		strncpy((char*)def->chanconf->master, master_lip_dev, WAN_IFNAME_SZ);
 
 #if defined(__NetBSD__) || defined(__FreeBSD__) || defined(__OpenBSD__)
 		config.arg = (void*)def->chanconf;
@@ -3568,7 +3568,7 @@
  * Convert decimal string to unsigned integer.
  * If len != 0 then only 'len' characters of the string are converted.
  */
-unsigned int dec_to_uint (unsigned char* str, int len)
+unsigned int dec_to_uint (char* str, int len)
 {
 	unsigned val;
 
@@ -3883,11 +3883,11 @@
 
 int has_config_changed(link_def_t *linkdef, char *name)
 {
-	unsigned char filename[50];
+	char filename[50];
 	//unsigned long checksum;
 	time_t modified;
 	struct stat statbuf;
-	unsigned char timeBuf[TIME_STRING_BUF];
+	char timeBuf[TIME_STRING_BUF];
 
 	sprintf(filename,"/etc/wanpipe/%s.conf",name);
 
@@ -4018,7 +4018,7 @@
 
 int device_syncup(char *devname)
 {
-	unsigned char filename[100];
+	char filename[100];
 	int err;
 
 	free_device_link(devname);
@@ -4125,7 +4125,7 @@
 	link_def_t* linkdef; 
 	int err=-EINVAL;
 	int dev=-1;
-	unsigned char filename[100];
+	char filename[100];
 
 	if (!link_defs){
 		if (card_name){
@@ -4250,7 +4250,7 @@
  *
  */
 
-int exec_command(unsigned char *rx_data)
+int exec_command(char *rx_data)
 {
 	int toknum;
 	char *card_str=NULL;
@@ -4378,7 +4378,7 @@
 	struct sockaddr_un address;
 	int sock,conn;
 	socklen_t addrLength;
-	unsigned char rx_data[100];
+	char rx_data[100];
 	int err;
 	int fp;
 	struct stat file_stat;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanec_apilib/wanec_api_lib.c wanpipe-3.1.4.6/util/wanec_apilib/wanec_api_lib.c
--- r3145/wanpipe-3.1.4.5/util/wanec_apilib/wanec_api_lib.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanec_apilib/wanec_api_lib.c	2007-09-30 21:56:18.000000000 -0400
@@ -750,7 +750,7 @@
 
 int wanec_api_lib_toneload(wan_ec_api_t *ec_api)
 {	
-	UINT8	tone_path[100];
+	char	tone_path[100];
 	int		err = 0;
 #if !defined(__WINDOWS__)
 	int		dev;
@@ -821,7 +821,7 @@
 		FILE		*output = NULL;
 		size_t		len;
 		int		cnt = 0;
-		unsigned char	filename[MAXPATHLEN];
+		char	filename[MAXPATHLEN];
 		
 		printf("%s: Reading Monitor Data ..",
 					ec_api->devname);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanec_client/wan_ecmain.h wanpipe-3.1.4.6/util/wanec_client/wan_ecmain.h
--- r3145/wanpipe-3.1.4.5/util/wanec_client/wan_ecmain.h	2007-02-09 12:49:20.000000000 -0500
+++ wanpipe-3.1.4.6/util/wanec_client/wan_ecmain.h	2007-09-30 21:55:12.000000000 -0400
@@ -32,7 +32,7 @@
 };
 
 typedef struct {
-	unsigned char	devname[WAN_DRVNAME_SZ+1];
+	char	devname[WAN_DRVNAME_SZ+1];
 //	unsigned char	if_name[WAN_IFNAME_SZ+1];
 	int		verbose;
 	
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/aftpipemon.c wanpipe-3.1.4.6/util/wanpipemon/aftpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/aftpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/aftpipemon.c	2007-09-30 21:34:11.000000000 -0400
@@ -170,7 +170,7 @@
 	
 	while(gui_cmd_menu_lookup[i].cmd_menu_ptr != NULL){
 		if (strcmp(cmd_name,gui_cmd_menu_lookup[i].cmd_menu_name) == 0){
-			cmd_menu=(char*)gui_cmd_menu_lookup[i].cmd_menu_ptr;
+			cmd_menu=(char**)gui_cmd_menu_lookup[i].cmd_menu_ptr;
 			while (strcmp(cmd_menu[j],".") != 0){
 				j++;
 			}
@@ -189,7 +189,7 @@
  *****************************************************************************/
 int AFTConfig(void)
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x=0;
    
 	protocol_cb_size = sizeof(wan_mgmt_t) + 
@@ -226,7 +226,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	
 	return(WAN_TRUE);
@@ -479,7 +479,7 @@
 	unsigned int i;
 	struct timeval to;
 	int timeout=0;
-	unsigned char date_string[100];
+	char date_string[100];
 	
 	gettimeofday(&to, NULL);
 	to.tv_sec = 0;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/atmpipemon.c wanpipe-3.1.4.6/util/wanpipemon/atmpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/atmpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/atmpipemon.c	2007-09-30 21:33:44.000000000 -0400
@@ -257,7 +257,7 @@
  *****************************************************************************/
 int ATMConfig(void)
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x=0;
    
 	protocol_cb_size = sizeof(wan_mgmt_t) + 
@@ -298,7 +298,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	
 	return(WAN_TRUE);
@@ -853,10 +853,10 @@
 						
 
 						printf("Cell Type: ");
-						switch(get_cell_type(trace_pkt->data, trace_pkt->real_length))
+						switch(get_cell_type((char*)trace_pkt->data, trace_pkt->real_length))
 						{
 						case ATM_USER_DATA_CELL:
-							decode_user_data_cell(trace_pkt->data,
+							decode_user_data_cell((char*)trace_pkt->data,
 										trace_pkt->real_length);
 							break;
 						default:
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/bpipemon.c wanpipe-3.1.4.6/util/wanpipemon/bpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/bpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/bpipemon.c	2007-09-30 21:46:00.000000000 -0400
@@ -164,7 +164,7 @@
  *****************************************************************************/
 int BITSTRMConfig(void)
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x=0;
    
 	protocol_cb_size = sizeof(wan_mgmt_t) + 
@@ -205,7 +205,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	
 	return(WAN_TRUE);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/cpipemon.c wanpipe-3.1.4.6/util/wanpipemon/cpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/cpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/cpipemon.c	2007-09-30 21:29:48.000000000 -0400
@@ -255,7 +255,7 @@
  *****************************************************************************/
 int CHDLCConfig(void)
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x=0;
    
 	protocol_cb_size = sizeof(wan_mgmt_t) + 
@@ -296,7 +296,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	
 	return(WAN_TRUE);
@@ -862,7 +862,7 @@
 	unsigned int i;
 	struct timeval to;
 	int timeout=0;
-	unsigned char date_string[100];
+	char date_string[100];
 	
 	gettimeofday(&to, NULL);
 	to.tv_sec = 0;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/dslpipemon.c wanpipe-3.1.4.6/util/wanpipemon/dslpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/dslpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/dslpipemon.c	2007-09-30 21:35:42.000000000 -0400
@@ -111,7 +111,7 @@
  *****************************************************************************/
 int ADSLConfig( void )
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x;
    
 	x = 0;
@@ -142,7 +142,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0){
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	protocol_cb_size=sizeof(wan_mgmt_t) + sizeof(wan_cmd_t) + sizeof(wan_trace_info_t) + 1;
 	return WAN_TRUE;
@@ -182,7 +182,7 @@
 	
 }
 
-static unsigned char *decode_modulation[]={
+static char *decode_modulation[]={
 "T1_413",
 "G_LITE",
 "G_DMT",
@@ -402,7 +402,7 @@
 	unsigned short curr_pos = 0;
 	wan_trace_pkt_t *trace_pkt;
 	unsigned int i, j;
-	unsigned char outstr[MAX_TRACE_BUF];
+	char outstr[MAX_TRACE_BUF];
 	int recv_buff = MDATALEN + 100;
 	fd_set ready;
 	struct timeval to;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/fpipemon.c wanpipe-3.1.4.6/util/wanpipemon/fpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/fpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/fpipemon.c	2007-09-30 21:28:54.000000000 -0400
@@ -291,7 +291,7 @@
 
    	if (wan_udp.wan_udphdr_return_code == 0) {
       		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-      		strcpy(codeversion, wan_udp.wan_udphdr_data);
+      		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
    	}
 
    	return(WAN_TRUE);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/ppipemon.c wanpipe-3.1.4.6/util/wanpipemon/ppipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/ppipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/ppipemon.c	2007-09-30 21:32:06.000000000 -0400
@@ -171,7 +171,7 @@
 
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 
 	return(WAN_TRUE);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/prot_trace.c wanpipe-3.1.4.6/util/wanpipemon/prot_trace.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/prot_trace.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/prot_trace.c	2007-09-30 21:43:09.000000000 -0400
@@ -79,9 +79,9 @@
 
 static void decode_chdlc_ip_transaction(cisco_slarp_t *cisco_slarp);
 static void print_ipv4_address(unsigned int address);
-static int decode_data_ipv4(char* data, unsigned short data_len);
+static int decode_data_ipv4(unsigned char* data, unsigned short data_len);
 static char* decode_tcp_level_protocol(unsigned short port);
-static void print_data_in_hex(char* data, unsigned short data_len);
+static void print_data_in_hex(unsigned char* data, unsigned short data_len);
 
 int match_trace_criteria(unsigned char *pkt, int len, int *dlci)
 {
@@ -110,7 +110,7 @@
 	unsigned int timestamp	=trace_iface->timestamp;
 
 	if (!(*trace_started)){
-		unsigned char date_string[100];
+		char date_string[100];
 		
 		date_string[0] = '\0';
 
@@ -567,7 +567,7 @@
 static int decode_chdlc(wp_trace_output_iface_t *trace_iface,
 		        int *trace_started)
 {
-	unsigned char *data	=trace_iface->data;
+	unsigned char *data	= trace_iface->data;
 
 	int inf_frame=0;
 	cisco_header_t *cisco_header = (cisco_header_t *)&data[0];
@@ -586,7 +586,7 @@
 		case CISCO_PACKET_IP:
 			printf("CISCO Packet IP-v4\n\n");
 			//decode data past Cisco header
-		     	decode_data_ipv4((char*)(cisco_header + 1),
+		     	decode_data_ipv4((unsigned char*)(cisco_header + 1),
 				trace_iface->len - sizeof(cisco_header_t));
       			break;
 
@@ -661,7 +661,7 @@
 #define IP_V4		4
 #define IP_V4_IHLEN  	5
 
-static int decode_data_ipv4(char* data, unsigned short data_len)
+static int decode_data_ipv4(unsigned char* data, unsigned short data_len)
 {
 	iphdr_t *ip_hdr = (iphdr_t*)data;
 	struct tcphdr * tcp_hdr;
@@ -762,10 +762,12 @@
 	case IPPROTO_RAW:      /* 255  */
 		printf("Raw IP packets");
 		break;
-	
+
+#if 0	
 	case IPPROTO_MAX:
 		printf("IPPROTO_MAX");
 		break;
+#endif
 	
 	default:
 		printf("Unknown (%d)\n", ip_hdr->w_ip_p);
@@ -841,7 +843,7 @@
 				(unsigned int)(address & 0xFF000000) >>24);
 }
 
-static void print_data_in_hex(char* data, unsigned short data_len)
+static void print_data_in_hex(unsigned char* data, unsigned short data_len)
 {
   	int i;
 
@@ -1530,7 +1532,7 @@
 	fwrite(&ph, sizeof(ph), 1, trace_iface->output_file);
 }
 
-static void get_ppp_magic_number(char* data, int len, char* outstr, char offset_flag)
+static void get_ppp_magic_number(unsigned char* data, int len, char* outstr, char offset_flag)
 {
 	if(offset_flag == 0){
 
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/ss7pipemon.c wanpipe-3.1.4.6/util/wanpipemon/ss7pipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/ss7pipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/ss7pipemon.c	2007-09-30 21:45:27.000000000 -0400
@@ -227,7 +227,7 @@
  *****************************************************************************/
 int SS7Config(void)
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x=0;
    
 	protocol_cb_size = sizeof(wan_mgmt_t) + 
@@ -268,7 +268,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	
 	return(WAN_TRUE);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/wangui.c wanpipe-3.1.4.6/util/wanpipemon/wangui.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/wangui.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/wangui.c	2007-09-30 21:44:44.000000000 -0400
@@ -147,10 +147,10 @@
 static int wan_if_ip_menu(void)
 {
 	int err=0;
-	unsigned char data[100];
-	unsigned char current[100];
-	unsigned char title[100];
-	unsigned char prompt[100];
+	char data[100];
+	char current[100];
+	char title[100];
+	char prompt[100];
 	int pipefds[2];	
 	pid_t pid;
 	int stat;
@@ -202,9 +202,9 @@
 static int wan_ip_menu(void)
 {
 	int err=0;
-	unsigned char data[100];
-	unsigned char title[100];
-	unsigned char prompt[100];
+	char data[100];
+	char title[100];
+	char prompt[100];
 	int pipefds[2];	
 	pid_t pid;
 	int stat;
@@ -291,10 +291,10 @@
 static int wan_iface_menu(void)
 {
 	int err=0;
-	unsigned char data[100];
-	unsigned char current[100];
-	unsigned char title[100];
-	unsigned char prompt[100];
+	char data[100];
+	char current[100];
+	char title[100];
+	char prompt[100];
 	int pipefds[2];	
 	pid_t pid;
 	int stat;
@@ -429,11 +429,11 @@
 static void wan_main_menu(void)
 {
 	int err=0;
-	unsigned char data[100];
-	unsigned char cmd_data[100];
-	unsigned char current[100];
-	unsigned char title[100];
-	unsigned char prompt[100];
+	char data[100];
+	char cmd_data[100];
+	char current[100];
+	char title[100];
+	char prompt[100];
 	int pipefds[2];	
 	pid_t pid;
 	int stat;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/wanpipemon.c wanpipe-3.1.4.6/util/wanpipemon/wanpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/wanpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/wanpipemon.c	2007-09-30 21:28:20.000000000 -0400
@@ -117,7 +117,7 @@
 int pcap_output=0;
 int pcap_prot=0;
 FILE *pcap_output_file;
-unsigned char pcap_output_file_name[50];
+char pcap_output_file_name[50];
 
 wanpipe_hdlc_engine_t *rx_hdlc_eng; 
 
@@ -401,7 +401,7 @@
 		return NULL;
 	}
 	
-	return wan_udp.wan_udphdr_data;
+	return (char*)wan_udp.wan_udphdr_data;
 }
 
 char* get_hardware_level_interface_name(char* interface_name)
@@ -856,25 +856,25 @@
 			}
 
 			if (argc == 3){
-				unsigned char *name=argv[i+1];
+				char *name=argv[i+1];
 				EXEC_NAME_FUNC(usage,name,());
 				return WAN_FALSE;
 			}
 
 			if (strcmp(argv[i+1], "chdlc") == 0){
-				strcpy(wan_udp.wan_udphdr_signature, UDP_CHDLC_SIGNATURE);
+				strcpy((char*)wan_udp.wan_udphdr_signature, UDP_CHDLC_SIGNATURE);
 				wan_protocol=WANCONFIG_CHDLC;
 			}else if (strcmp(argv[i+1], "fr") == 0){
-				strcpy(wan_udp.wan_udphdr_signature, UDP_FR_SIGNATURE);
+				strcpy((char*)wan_udp.wan_udphdr_signature, UDP_FR_SIGNATURE);
 				wan_protocol=WANCONFIG_FR;
 			}else if (strcmp(argv[i+1], "ppp") == 0){
-				strcpy(wan_udp.wan_udphdr_signature, UDP_PPP_SIGNATURE);
+				strcpy((char*)wan_udp.wan_udphdr_signature, UDP_PPP_SIGNATURE);
 				wan_protocol=WANCONFIG_PPP;
 			}else if (strcmp(argv[i+1], "x25") == 0){
-				strcpy(wan_udp.wan_udphdr_signature, UDP_X25_SIGNATURE);
+				strcpy((char*)wan_udp.wan_udphdr_signature, UDP_X25_SIGNATURE);
 				wan_protocol=WANCONFIG_X25;
 			}else if (strcmp(argv[i+1], "adsl") == 0){
-				strcpy(wan_udp.wan_udphdr_signature, GLOBAL_UDP_SIGNATURE);
+				strcpy((char*)wan_udp.wan_udphdr_signature, GLOBAL_UDP_SIGNATURE);
 				wan_protocol=WANCONFIG_ADSL;
 			}else{
 				usage();
@@ -1314,7 +1314,7 @@
 	char command[MAX_CMD_LENGTH+1];
 	int err = 0;
 
-	strcpy(wan_udp.wan_udphdr_signature, GLOBAL_UDP_SIGNATURE);
+	strcpy((char*)wan_udp.wan_udphdr_signature, GLOBAL_UDP_SIGNATURE);
 	sprintf(pcap_output_file_name,"wp_trace_pcap.bin");
 
 	signal(SIGHUP,sig_end);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/wanpipemon.h wanpipe-3.1.4.6/util/wanpipemon/wanpipemon.h
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/wanpipemon.h	2007-03-06 11:06:29.000000000 -0500
+++ wanpipe-3.1.4.6/util/wanpipemon/wanpipemon.h	2007-09-30 21:27:47.000000000 -0400
@@ -69,7 +69,7 @@
 extern int pcap_output;
 extern int pcap_prot;
 extern FILE *pcap_output_file;
-extern unsigned char pcap_output_file_name[];
+extern char pcap_output_file_name[];
 
 
 #define MAX_CMD_ARG 10
@@ -87,7 +87,7 @@
 
 struct cmd_menu_lookup_t
 {
-	unsigned char *cmd_menu_name;
+	char *cmd_menu_name;
 	char **cmd_menu_ptr;
 };
 
@@ -107,7 +107,6 @@
 extern char ** BITSTRMget_main_menu(int *len);
 extern char ** BITSTRMget_cmd_menu(char *cmd_name,int *len);
 
-
 #endif
 extern char ** ADSLget_main_menu(int *len);
 extern char ** ATMget_main_menu(int *len);
@@ -128,7 +127,7 @@
 
 struct fun_protocol {
 	int		protocol_id;
-	unsigned char   prot_name[10];
+	char   		prot_name[10];
 	config_t*	config;
 	usage_t*	usage;
 	main_t*		main;
@@ -364,7 +363,7 @@
 #define ALL_X25 (DATA|PROT)
 
 typedef struct {
-	unsigned char prot_name[15];
+	char prot_name[15];
 	signed char prot_index;
 	unsigned int  pcap_prot;
 } trace_prot_t;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon/xpipemon.c wanpipe-3.1.4.6/util/wanpipemon/xpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon/xpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon/xpipemon.c	2007-09-30 21:30:37.000000000 -0400
@@ -101,7 +101,7 @@
 
    	if (wan_udp.wan_udphdr_return_code == 0) {
       		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-      		strcpy(codeversion, wan_udp.wan_udphdr_data);
+      		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
    	}
 
 	protocol_cb_size=sizeof(wan_mgmt_t) + sizeof(wan_cmd_t) + 1;
@@ -425,7 +425,7 @@
 {
 	time_t time_val=trace_info->sec;
 	struct tm *time_tm = localtime(&time_val);
-	unsigned char tmp_time[50];
+	char tmp_time[50];
 
 	/* week day */
 	//strftime(tmp_time,sizeof(tmp_time),"%a",time_tm);
@@ -458,7 +458,7 @@
 {
   	fd_set ready;
    	struct timeval to;
-        unsigned char *trace_data;
+        char *trace_data;
         trace_data_t *trace_info;
 	wp_trace_output_iface_t trace_iface;
    
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/aftpipemon.c wanpipe-3.1.4.6/util/wanpipemon_legacy/aftpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/aftpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/aftpipemon.c	2007-09-30 23:24:39.000000000 -0400
@@ -181,7 +181,7 @@
  *****************************************************************************/
 int AFTConfig(void)
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x=0;
    
 	protocol_cb_size = sizeof(wan_mgmt_t) + 
@@ -218,7 +218,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	
 	return(WAN_TRUE);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/atmpipemon.c wanpipe-3.1.4.6/util/wanpipemon_legacy/atmpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/atmpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/atmpipemon.c	2007-09-30 23:19:26.000000000 -0400
@@ -160,7 +160,7 @@
 static void read_ft1_te1_56k_config( void );
 
 /* Other routines */
-static int get_cell_type(char* data, int len);
+static int get_cell_type(unsigned char* data, int len);
 void decode_user_data_cell(char* data, int len);
 
 static char *gui_main_menu[]={
@@ -257,7 +257,7 @@
  *****************************************************************************/
 int ATMConfig(void)
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x=0;
    
 	protocol_cb_size = sizeof(wan_mgmt_t) + 
@@ -298,7 +298,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	
 	return(WAN_TRUE);
@@ -856,7 +856,7 @@
 						switch(get_cell_type(trace_pkt->data, trace_pkt->real_length))
 						{
 						case ATM_USER_DATA_CELL:
-							decode_user_data_cell(trace_pkt->data,
+							decode_user_data_cell((char*)trace_pkt->data,
 										trace_pkt->real_length);
 							break;
 						default:
@@ -890,7 +890,7 @@
 }; /* line_trace */
 
 
-static int get_cell_type(char* data, int len)
+static int get_cell_type(unsigned char* data, int len)
 {
 	ATM_HEADER_STRUCT * atm_hdr_ptr = (ATM_HEADER_STRUCT * )data;
 	ATM_CELL_STRUCT * ATM_cell_ptr = (ATM_CELL_STRUCT * )data;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/bpipemon.c wanpipe-3.1.4.6/util/wanpipemon_legacy/bpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/bpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/bpipemon.c	2007-09-30 23:21:55.000000000 -0400
@@ -164,7 +164,7 @@
  *****************************************************************************/
 int BITSTRMConfig(void)
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x=0;
    
 	protocol_cb_size = sizeof(wan_mgmt_t) + 
@@ -205,7 +205,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	
 	return(WAN_TRUE);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/cpipemon.c wanpipe-3.1.4.6/util/wanpipemon_legacy/cpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/cpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/cpipemon.c	2007-09-30 23:17:12.000000000 -0400
@@ -236,7 +236,7 @@
  *****************************************************************************/
 int CHDLCConfig(void)
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x=0;
    
 	protocol_cb_size = sizeof(wan_mgmt_t) + 
@@ -277,7 +277,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	
 	return(WAN_TRUE);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/dslpipemon.c wanpipe-3.1.4.6/util/wanpipemon_legacy/dslpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/dslpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/dslpipemon.c	2007-09-30 23:23:54.000000000 -0400
@@ -111,7 +111,7 @@
  *****************************************************************************/
 int ADSLConfig( void )
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x;
    
 	x = 0;
@@ -142,7 +142,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0){
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	protocol_cb_size=sizeof(wan_mgmt_t) + sizeof(wan_cmd_t) + sizeof(wan_trace_info_t) + 1;
 	return TRUE;
@@ -182,7 +182,7 @@
 	
 }
 
-static unsigned char *decode_modulation[]={
+static char *decode_modulation[]={
 "T1_413",
 "G_LITE",
 "G_DMT",
@@ -402,7 +402,7 @@
 	unsigned short curr_pos = 0;
 	wan_trace_pkt_t *trace_pkt;
 	unsigned int i, j;
-	unsigned char outstr[MAX_TRACE_BUF];
+	char outstr[MAX_TRACE_BUF];
 	int recv_buff = MDATALEN + 100;
 	fd_set ready;
 	struct timeval to;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/fpipemon.c wanpipe-3.1.4.6/util/wanpipemon_legacy/fpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/fpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/fpipemon.c	2007-09-30 23:16:50.000000000 -0400
@@ -283,7 +283,7 @@
 
    	if (wan_udp.wan_udphdr_return_code == 0) {
       		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-      		strcpy(codeversion, wan_udp.wan_udphdr_data);
+      		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
    	}
 
    	return(WAN_TRUE);
@@ -885,7 +885,7 @@
 		output_start_xml_header("Global DLCI Status");
 		output_xml_val_asc("Channel Status",wan_udp.wan_udphdr_data[0] ? "OPERATIVE" : "INOPERATIVE");	
 		if (wan_udp.wan_udphdr_data_len > 2){
-			unsigned char str_val[50];
+			char str_val[50];
 			int cnt_val=0;
 			for (i=1;i<wan_udp.wan_udphdr_data_len;){
 				output_xml_val_data("DLCI",*((unsigned short*)&wan_udp.wan_udphdr_data[i]));
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/ppipemon.c wanpipe-3.1.4.6/util/wanpipemon_legacy/ppipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/ppipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/ppipemon.c	2007-09-30 23:24:15.000000000 -0400
@@ -153,7 +153,7 @@
 
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 
 	return(WAN_TRUE);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/prot_trace.c wanpipe-3.1.4.6/util/wanpipemon_legacy/prot_trace.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/prot_trace.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/prot_trace.c	2007-09-30 23:21:33.000000000 -0400
@@ -77,9 +77,9 @@
 
 static void decode_chdlc_ip_transaction(cisco_slarp_t *cisco_slarp);
 static void print_ipv4_address(unsigned int address);
-static int decode_data_ipv4(char* data, unsigned short data_len);
+static int decode_data_ipv4(unsigned char* data, unsigned short data_len);
 static char* decode_tcp_level_protocol(unsigned short port);
-static void print_data_in_hex(char* data, unsigned short data_len);
+static void print_data_in_hex(unsigned char* data, unsigned short data_len);
 
 int match_trace_criteria(unsigned char *pkt, int len, int *dlci)
 {
@@ -108,7 +108,7 @@
 	unsigned int timestamp	=trace_iface->timestamp;
 
 	if (!(*trace_started)){
-		unsigned char date_string[100];
+		char date_string[100];
 		
 		date_string[0] = '\0';
 
@@ -584,7 +584,7 @@
 		case CISCO_PACKET_IP:
 			printf("CISCO Packet IP-v4\n\n");
 			//decode data past Cisco header
-		     	decode_data_ipv4((char*)(cisco_header + 1),
+		     	decode_data_ipv4((unsigned char*)(cisco_header + 1),
 				trace_iface->len - sizeof(cisco_header_t));
       			break;
 
@@ -659,7 +659,7 @@
 #define IP_V4		4
 #define IP_V4_IHLEN  	5
 
-static int decode_data_ipv4(char* data, unsigned short data_len)
+static int decode_data_ipv4(unsigned char* data, unsigned short data_len)
 {
 	iphdr_t *ip_hdr = (iphdr_t*)data;
 	struct tcphdr * tcp_hdr;
@@ -760,10 +760,12 @@
 	case IPPROTO_RAW:      /* 255  */
 		printf("Raw IP packets");
 		break;
-	
+
+#if 0	
 	case IPPROTO_MAX:
 		printf("IPPROTO_MAX");
 		break;
+#endif
 	
 	default:
 		printf("Unknown (%d)\n", ip_hdr->w_ip_p);
@@ -839,7 +841,7 @@
 				(unsigned int)(address & 0xFF000000) >>24);
 }
 
-static void print_data_in_hex(char* data, unsigned short data_len)
+static void print_data_in_hex(unsigned char* data, unsigned short data_len)
 {
   	int i;
 
@@ -1526,7 +1528,7 @@
 	fwrite(&ph, sizeof(ph), 1, trace_iface->output_file);
 }
 
-static void get_ppp_magic_number(char* data, int len, char* outstr, char offset_flag)
+static void get_ppp_magic_number(unsigned char* data, int len, char* outstr, char offset_flag)
 {
 	if(offset_flag == 0){
 
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/ss7pipemon.c wanpipe-3.1.4.6/util/wanpipemon_legacy/ss7pipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/ss7pipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/ss7pipemon.c	2007-09-30 23:25:05.000000000 -0400
@@ -227,7 +227,7 @@
  *****************************************************************************/
 int SS7Config(void)
 {
-	unsigned char codeversion[10];
+	char codeversion[10];
 	unsigned char x=0;
    
 	protocol_cb_size = sizeof(wan_mgmt_t) + 
@@ -268,7 +268,7 @@
 	DO_COMMAND(wan_udp);
 	if (wan_udp.wan_udphdr_return_code == 0) {
 		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-		strcpy(codeversion, wan_udp.wan_udphdr_data);
+		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
 	}
 	
 	return(WAN_TRUE);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/wangui.c wanpipe-3.1.4.6/util/wanpipemon_legacy/wangui.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/wangui.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/wangui.c	2007-09-30 23:23:02.000000000 -0400
@@ -147,10 +147,10 @@
 static int wan_if_ip_menu(void)
 {
 	int err=0;
-	unsigned char data[100];
-	unsigned char current[100];
-	unsigned char title[100];
-	unsigned char prompt[100];
+	char data[100];
+	char current[100];
+	char title[100];
+	char prompt[100];
 	int pipefds[2];	
 	pid_t pid;
 	int stat;
@@ -202,9 +202,9 @@
 static int wan_ip_menu(void)
 {
 	int err=0;
-	unsigned char data[100];
-	unsigned char title[100];
-	unsigned char prompt[100];
+	char data[100];
+	char title[100];
+	char prompt[100];
 	int pipefds[2];	
 	pid_t pid;
 	int stat;
@@ -291,10 +291,10 @@
 static int wan_iface_menu(void)
 {
 	int err=0;
-	unsigned char data[100];
-	unsigned char current[100];
-	unsigned char title[100];
-	unsigned char prompt[100];
+	char data[100];
+	char current[100];
+	char title[100];
+	char prompt[100];
 	int pipefds[2];	
 	pid_t pid;
 	int stat;
@@ -429,11 +429,11 @@
 static void wan_main_menu(void)
 {
 	int err=0;
-	unsigned char data[100];
-	unsigned char cmd_data[100];
-	unsigned char current[100];
-	unsigned char title[100];
-	unsigned char prompt[100];
+	char data[100];
+	char cmd_data[100];
+	char current[100];
+	char title[100];
+	char prompt[100];
 	int pipefds[2];	
 	pid_t pid;
 	int stat;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/wanpipemon.h wanpipe-3.1.4.6/util/wanpipemon_legacy/wanpipemon.h
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/wanpipemon.h	2007-02-09 12:49:20.000000000 -0500
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/wanpipemon.h	2007-09-30 23:16:19.000000000 -0400
@@ -53,7 +53,7 @@
 extern int pcap_output;
 extern int pcap_prot;
 extern FILE *pcap_output_file;
-extern unsigned char pcap_output_file_name[];
+extern char pcap_output_file_name[];
 
 
 #define MAX_CMD_ARG 10
@@ -70,7 +70,7 @@
 
 struct cmd_menu_lookup_t
 {
-	unsigned char *cmd_menu_name;
+	char *cmd_menu_name;
 	char **cmd_menu_ptr;
 };
 
@@ -109,7 +109,7 @@
 
 struct fun_protocol {
 	int		protocol_id;
-	unsigned char   prot_name[10];
+	char   prot_name[10];
 	config_t*	config;
 	usage_t*	usage;
 	main_t*		main;
@@ -341,7 +341,7 @@
 #define ALL_X25 (DATA|PROT)
 
 typedef struct {
-	unsigned char prot_name[15];
+	char prot_name[15];
 	signed char prot_index;
 	unsigned int  pcap_prot;
 } trace_prot_t;
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/wanpipemon_legacy.c wanpipe-3.1.4.6/util/wanpipemon_legacy/wanpipemon_legacy.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/wanpipemon_legacy.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/wanpipemon_legacy.c	2007-09-30 23:15:44.000000000 -0400
@@ -102,7 +102,7 @@
 int pcap_output=0;
 int pcap_prot=0;
 FILE *pcap_output_file;
-unsigned char pcap_output_file_name[50];
+char pcap_output_file_name[50];
 
 trace_prot_t trace_prot_opt[]={ 
 	{"FR", FRAME,107},
@@ -517,25 +517,25 @@
 			}
 
 			if (argc == 3){
-				unsigned char *name=argv[i+1];
+				char *name=argv[i+1];
 				EXEC_NAME_FUNC(usage,name,());
 				return WAN_FALSE;
 			}
 
 			if (strcmp(argv[i+1], "chdlc") == 0){
-				strcpy(wan_udp.wan_udphdr_signature, UDP_CHDLC_SIGNATURE);
+				strcpy((char*)wan_udp.wan_udphdr_signature, UDP_CHDLC_SIGNATURE);
 				wan_protocol=WANCONFIG_CHDLC;
 			}else if (strcmp(argv[i+1], "fr") == 0){
-				strcpy(wan_udp.wan_udphdr_signature, UDP_FR_SIGNATURE);
+				strcpy((char*)wan_udp.wan_udphdr_signature, UDP_FR_SIGNATURE);
 				wan_protocol=WANCONFIG_FR;
 			}else if (strcmp(argv[i+1], "ppp") == 0){
-				strcpy(wan_udp.wan_udphdr_signature, UDP_PPP_SIGNATURE);
+				strcpy((char*)wan_udp.wan_udphdr_signature, UDP_PPP_SIGNATURE);
 				wan_protocol=WANCONFIG_PPP;
 			}else if (strcmp(argv[i+1], "x25") == 0){
-				strcpy(wan_udp.wan_udphdr_signature, UDP_X25_SIGNATURE);
+				strcpy((char*)wan_udp.wan_udphdr_signature, UDP_X25_SIGNATURE);
 				wan_protocol=WANCONFIG_X25;
 			}else if (strcmp(argv[i+1], "adsl") == 0){
-				strcpy(wan_udp.wan_udphdr_signature, GLOBAL_UDP_SIGNATURE);
+				strcpy((char*)wan_udp.wan_udphdr_signature, GLOBAL_UDP_SIGNATURE);
 				wan_protocol=WANCONFIG_ADSL;
 			}else{
 				usage();
@@ -962,7 +962,7 @@
 {
 	char command[6];
 
-	strcpy(wan_udp.wan_udphdr_signature, GLOBAL_UDP_SIGNATURE);
+	strcpy((char*)wan_udp.wan_udphdr_signature, GLOBAL_UDP_SIGNATURE);
 	sprintf(pcap_output_file_name,"wp_trace_pcap.bin");
 
 	signal(SIGHUP,sig_end);
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/xpipemon.c wanpipe-3.1.4.6/util/wanpipemon_legacy/xpipemon.c
--- r3145/wanpipe-3.1.4.5/util/wanpipemon_legacy/xpipemon.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wanpipemon_legacy/xpipemon.c	2007-09-30 23:18:17.000000000 -0400
@@ -101,7 +101,7 @@
 
    	if (wan_udp.wan_udphdr_return_code == 0) {
       		wan_udp.wan_udphdr_data[wan_udp.wan_udphdr_data_len] = 0;
-      		strcpy(codeversion, wan_udp.wan_udphdr_data);
+      		strcpy(codeversion, (char*)wan_udp.wan_udphdr_data);
    	}
 
 	protocol_cb_size=sizeof(wan_mgmt_t) + sizeof(wan_cmd_t) + 1;
@@ -425,7 +425,7 @@
 {
 	time_t time_val=trace_info->sec;
 	struct tm *time_tm = localtime(&time_val);
-	unsigned char tmp_time[50];
+	char tmp_time[50];
 
 	/* week day */
 	//strftime(tmp_time,sizeof(tmp_time),"%a",time_tm);
@@ -458,7 +458,7 @@
 {
   	fd_set ready;
    	struct timeval to;
-        unsigned char *trace_data;
+        char *trace_data;
         trace_data_t *trace_info;
 	wp_trace_output_iface_t trace_iface;
    
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wan_plxctrl/wan_plxctrl.c wanpipe-3.1.4.6/util/wan_plxctrl/wan_plxctrl.c
--- r3145/wanpipe-3.1.4.5/util/wan_plxctrl/wan_plxctrl.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wan_plxctrl/wan_plxctrl.c	2007-09-30 23:26:41.000000000 -0400
@@ -77,11 +77,11 @@
 void PEX_8111Read(void *info, int addr, int *data)
 {	
 	if (addr < 0x1000){
-		exec_read_cmd(info, addr, 4, data);
+		exec_read_cmd(info, addr, 4, (unsigned int*)data);
 	}else if (addr >= 0x1000 && addr <= 0x1FFF){
 			
 		exec_write_cmd(info, 0x84, 4, addr);
-		exec_read_cmd(info, 0x88, 4, data);
+		exec_read_cmd(info, 0x88, 4, (unsigned int*)data);
 	}	
 }
  
diff -dur --exclude='*.svn' --exclude='*.cmd' --exclude='libsangoma*' --exclude='sangoma_mgd*' r3145/wanpipe-3.1.4.5/util/wan_plxctrl/wan_plxup.c wanpipe-3.1.4.6/util/wan_plxctrl/wan_plxup.c
--- r3145/wanpipe-3.1.4.5/util/wan_plxctrl/wan_plxup.c	2007-04-24 19:14:43.000000000 -0400
+++ wanpipe-3.1.4.6/util/wan_plxctrl/wan_plxup.c	2007-09-30 23:27:04.000000000 -0400
@@ -212,7 +212,7 @@
 }
 
 
-unsigned char	buffer[WAN_PLXUP_MAX_ESIZE];
+char	buffer[WAN_PLXUP_MAX_ESIZE];
 static int wan_plxup_write_cmd(wan_plxup_t *info)
 {
 	FILE		*f;
