diff --git a/apps/app_adsiprog.c b/apps/app_adsiprog.c
index b9d3c096ef12891edcc442adda0939a48489dfe4..21829650158f2b506881e1318cfd2c2f70d3818c 100755
--- a/apps/app_adsiprog.c
+++ b/apps/app_adsiprog.c
@@ -161,9 +161,9 @@ struct adsi_script {
 	struct adsi_flag flags[7];
 
 	/* Stuff from adsi script */
-	char sec[5];
+	unsigned char sec[5];
 	char desc[19];
-	char fdn[5];
+	unsigned char fdn[5];
 	int ver;
 };
 
@@ -1427,7 +1427,7 @@ static int adsi_prog(struct ast_channel *chan, char *script)
 {
 	struct adsi_script *scr;
 	int x;
-	char buf[1024];
+	unsigned char buf[1024];
 	int bytes;
 	scr = compile_script(script);
 	if (!scr) 
diff --git a/apps/app_getcpeid.c b/apps/app_getcpeid.c
index 1ae5d2ffa9c13a623dfb67f16010447b416dbebf..1c0277489b6a7056aed73bc637abefcdd267666e 100755
--- a/apps/app_getcpeid.c
+++ b/apps/app_getcpeid.c
@@ -46,7 +46,7 @@ LOCAL_USER_DECL;
 static int cpeid_setstatus(struct ast_channel *chan, char *stuff[], int voice)
 {
 	int justify[5] = { ADSI_JUST_CENT, ADSI_JUST_LEFT, ADSI_JUST_LEFT, ADSI_JUST_LEFT };
-	unsigned char *tmp[5];
+	char *tmp[5];
 	int x;
 	for (x=0;x<4;x++)
 		tmp[x] = stuff[x];
diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c
index 4a2876e55ef06febbf3f7c1e0678417deb9ecb67..c9003c6e823fd7f9e96b4d0566a9b447edbff40d 100755
--- a/apps/app_voicemail.c
+++ b/apps/app_voicemail.c
@@ -351,8 +351,8 @@ static char pagerfromstring[100];
 static char emailtitle[100];
 static char charset[32] = "ISO-8859-1";
 
-static char adsifdn[4] = "\x00\x00\x00\x0F";
-static char adsisec[4] = "\x9B\xDB\xF7\xAC";
+static unsigned char adsifdn[4] = "\x00\x00\x00\x0F";
+static unsigned char adsisec[4] = "\x9B\xDB\xF7\xAC";
 static int adsiver = 1;
 static char emaildateformat[32] = "%A, %B %d, %Y at %r";
 
@@ -2685,7 +2685,7 @@ static int adsi_logo(unsigned char *buf)
 
 static int adsi_load_vmail(struct ast_channel *chan, int *useadsi)
 {
-	char buf[256];
+	unsigned char buf[256];
 	int bytes=0;
 	int x;
 	char num[5];
@@ -2831,7 +2831,7 @@ static void adsi_begin(struct ast_channel *chan, int *useadsi)
 
 static void adsi_login(struct ast_channel *chan)
 {
-	char buf[256];
+	unsigned char buf[256];
 	int bytes=0;
 	unsigned char keys[8];
 	int x;
@@ -2857,7 +2857,7 @@ static void adsi_login(struct ast_channel *chan)
 
 static void adsi_password(struct ast_channel *chan)
 {
-	char buf[256];
+	unsigned char buf[256];
 	int bytes=0;
 	unsigned char keys[8];
 	int x;
@@ -2879,7 +2879,7 @@ static void adsi_password(struct ast_channel *chan)
 
 static void adsi_folders(struct ast_channel *chan, int start, char *label)
 {
-	char buf[256];
+	unsigned char buf[256];
 	int bytes=0;
 	unsigned char keys[8];
 	int x,y;
@@ -2909,7 +2909,8 @@ static void adsi_folders(struct ast_channel *chan, int start, char *label)
 static void adsi_message(struct ast_channel *chan, struct vm_state *vms)
 {
 	int bytes=0;
-	char buf[256], buf1[256], buf2[256];
+	unsigned char buf[256]; 
+	char buf1[256], buf2[256];
 	char fn2[256];
 
 	char cid[256]="";
@@ -2930,16 +2931,16 @@ static void adsi_message(struct ast_channel *chan, struct vm_state *vms)
 	f = fopen(fn2, "r");
 	if (f) {
 		while (!feof(f)) {	
-			fgets(buf, sizeof(buf), f);
+			fgets((char *)buf, sizeof(buf), f);
 			if (!feof(f)) {
 				char *stringp=NULL;
-				stringp=buf;
+				stringp = (char *)buf;
 				strsep(&stringp, "=");
 				val = strsep(&stringp, "=");
 				if (val && !ast_strlen_zero(val)) {
-					if (!strcmp(buf, "callerid"))
+					if (!strcmp((char *)buf, "callerid"))
 						ast_copy_string(cid, val, sizeof(cid));
-					if (!strcmp(buf, "origdate"))
+					if (!strcmp((char *)buf, "origdate"))
 						ast_copy_string(datetime, val, sizeof(datetime));
 				}
 			}
@@ -3001,7 +3002,7 @@ static void adsi_message(struct ast_channel *chan, struct vm_state *vms)
 static void adsi_delete(struct ast_channel *chan, struct vm_state *vms)
 {
 	int bytes=0;
-	char buf[256];
+	unsigned char buf[256];
 	unsigned char keys[8];
 
 	int x;
@@ -3045,7 +3046,8 @@ static void adsi_delete(struct ast_channel *chan, struct vm_state *vms)
 
 static void adsi_status(struct ast_channel *chan, struct vm_state *vms)
 {
-	char buf[256] = "", buf1[256] = "", buf2[256] = "";
+	unsigned char buf[256] = "";
+	char buf1[256] = "", buf2[256] = "";
 	int bytes=0;
 	unsigned char keys[8];
 	int x;
@@ -3091,7 +3093,8 @@ static void adsi_status(struct ast_channel *chan, struct vm_state *vms)
 
 static void adsi_status2(struct ast_channel *chan, struct vm_state *vms)
 {
-	char buf[256] = "", buf1[256] = "", buf2[256] = "";
+	unsigned char buf[256] = "";
+	char buf1[256] = "", buf2[256] = "";
 	int bytes=0;
 	unsigned char keys[8];
 	int x;
@@ -3146,7 +3149,7 @@ static void adsi_clear(struct ast_channel *chan)
 
 static void adsi_goodbye(struct ast_channel *chan)
 {
-	char buf[256];
+	unsigned char buf[256];
 	int bytes=0;
 
 	if (!adsi_available(chan))
@@ -4522,7 +4525,7 @@ static int vm_newuser(struct ast_channel *chan, struct ast_vm_user *vmu, struct
 	char newpassword[80] = "";
 	char newpassword2[80] = "";
 	char prefile[256]="";
-	char buf[256];
+	unsigned char buf[256];
 	int bytes=0;
 
 	if (adsi_available(chan)) {
@@ -4596,7 +4599,7 @@ static int vm_options(struct ast_channel *chan, struct ast_vm_user *vmu, struct
 	char newpassword[80] = "";
 	char newpassword2[80] = "";
 	char prefile[256]="";
-	char buf[256];
+	unsigned char buf[256];
 	int bytes=0;
 
 	if (adsi_available(chan))
@@ -4691,7 +4694,7 @@ static int vm_tempgreeting(struct ast_channel *chan, struct ast_vm_user *vmu, st
 	int retries = 0;
 	int duration = 0;
 	char prefile[256]="";
-	char buf[256];
+	unsigned char buf[256];
 	int bytes=0;
 
 	if (adsi_available(chan))
diff --git a/include/asterisk/adsi.h b/include/asterisk/adsi.h
index c0fb360199f2f5ce1c9649edded9a3f33762856e..bc517919999e973aa0e5a37a01cbe83c0c115f11 100755
--- a/include/asterisk/adsi.h
+++ b/include/asterisk/adsi.h
@@ -127,7 +127,7 @@
  */
 extern int adsi_channel_init(struct ast_channel *chan);
 
-extern int adsi_begin_download(struct ast_channel *chan, unsigned char *service, unsigned char *fdn, unsigned char *sec, int version);
+extern int adsi_begin_download(struct ast_channel *chan, char *service, unsigned char *fdn, unsigned char *sec, int version);
 
 extern int adsi_end_download(struct ast_channel *chan);
 
@@ -152,7 +152,7 @@ extern int adsi_channel_restore(struct ast_channel *chan);
  * Return 0 on success (or adsi unavailable) and -1 on hangup
  *
  */
-extern int adsi_print(struct ast_channel *chan, unsigned char **lines, int *align, int voice);
+extern int adsi_print(struct ast_channel *chan, char **lines, int *align, int voice);
 
 /*! Check if scripts for a given app are already loaded.  Version may be -1 */
 /*   if any version is okay, or 0-255 for a specific version. */
@@ -221,7 +221,7 @@ extern int adsi_get_cpeinfo(struct ast_channel *chan, int *width, int *height, i
  *
  */
 
-extern int adsi_download_connect(unsigned char *buf, unsigned char *service, unsigned char *fdn, unsigned char *sec, int ver);
+extern int adsi_download_connect(unsigned char *buf, char *service, unsigned char *fdn, unsigned char *sec, int ver);
 
 /*! Disconnects a running session */
 /*!
@@ -283,7 +283,7 @@ extern int adsi_available(struct ast_channel *chan);
  *
  */
 
-extern int adsi_display(unsigned char *buf, int page, int line, int just, int wrap, unsigned char *col1, unsigned char *col2);
+extern int adsi_display(unsigned char *buf, int page, int line, int just, int wrap, char *col1, char *col2);
 
 /*! Sets the current line and page */ 
 /*!
@@ -309,7 +309,7 @@ extern int adsi_set_line(unsigned char *buf, int page, int line);
  * Returns number of bytes added to buffer or -1 on error.
  *
  */
-extern int adsi_load_soft_key(unsigned char *buf, int key, unsigned char *llabel, unsigned char *slabel, unsigned char *ret, int data);
+extern int adsi_load_soft_key(unsigned char *buf, int key, char *llabel, char *slabel, char *ret, int data);
 
 /*! Set which soft keys should be displayed */
 /*!
@@ -348,6 +348,6 @@ extern int adsi_input_control(unsigned char *buf, int page, int line, int displa
  * Returns number of bytes added to buffer or -1 on error.
  *
  */
-extern int adsi_input_format(unsigned char *buf, int num, int dir, int wrap, unsigned char *format1, unsigned char *format2);
+extern int adsi_input_format(unsigned char *buf, int num, int dir, int wrap, char *format1, char *format2);
 
 #endif /* _ASTERISK_ADSI_H */
diff --git a/res/res_adsi.c b/res/res_adsi.c
index 99c567677cb319c5b780decb7d6a8c6628f52e1b..2669cd6441bd4ac479b65f576b4e8417133ca73e 100755
--- a/res/res_adsi.c
+++ b/res/res_adsi.c
@@ -306,7 +306,7 @@ static int __adsi_transmit_messages(struct ast_channel *chan, unsigned char **ms
 	
 }
 
-int adsi_begin_download(struct ast_channel *chan, unsigned char *service, unsigned char *fdn, unsigned char *sec, int version)
+int adsi_begin_download(struct ast_channel *chan, char *service, unsigned char *fdn, unsigned char *sec, int version)
 {
 	int bytes;
 	unsigned char buf[256];
@@ -428,7 +428,7 @@ static inline int ccopy(unsigned char *dst, unsigned char *src, int max)
 	return x;
 }
 
-int adsi_load_soft_key(unsigned char *buf, int key, unsigned char *llabel, unsigned char *slabel, unsigned char *ret, int data)
+int adsi_load_soft_key(unsigned char *buf, int key, char *llabel, char *slabel, char *ret, int data)
 {
 	int bytes=0;
 
@@ -442,13 +442,13 @@ int adsi_load_soft_key(unsigned char *buf, int key, unsigned char *llabel, unsig
 	buf[bytes++] = key;
 
 	/* Carefully copy long label */
-	bytes += ccopy(buf + bytes, llabel, 18);
+	bytes += ccopy(buf + bytes, (unsigned char *)llabel, 18);
 
 	/* Place delimiter */
 	buf[bytes++] = 0xff;
 
 	/* Short label */
-	bytes += ccopy(buf + bytes, slabel, 7);
+	bytes += ccopy(buf + bytes, (unsigned char *)slabel, 7);
 
 
 	/* If specified, copy return string */
@@ -458,7 +458,7 @@ int adsi_load_soft_key(unsigned char *buf, int key, unsigned char *llabel, unsig
 		if (data)
 			buf[bytes++] = ADSI_SWITCH_TO_DATA2;
 		/* Carefully copy return string */
-		bytes += ccopy(buf + bytes, ret, 20);
+		bytes += ccopy(buf + bytes, (unsigned char *)ret, 20);
 
 	}
 	/* Replace parameter length */
@@ -490,7 +490,7 @@ int adsi_connect_session(unsigned char *buf, unsigned char *fdn, int ver)
 
 }
 
-int adsi_download_connect(unsigned char *buf, unsigned char *service,  unsigned char *fdn, unsigned char *sec, int ver)
+int adsi_download_connect(unsigned char *buf, char *service,  unsigned char *fdn, unsigned char *sec, int ver)
 {
 	int bytes=0;
 	int x;
@@ -502,7 +502,7 @@ int adsi_download_connect(unsigned char *buf, unsigned char *service,  unsigned
 	bytes++;
 
 	/* Primary column */
-	bytes+= ccopy(buf + bytes, service, 18);
+	bytes+= ccopy(buf + bytes, (unsigned char *)service, 18);
 
 	/* Delimiter */
 	buf[bytes++] = 0xff;
@@ -774,7 +774,7 @@ int adsi_download_disconnect(unsigned char *buf)
 }
 
 int adsi_display(unsigned char *buf, int page, int line, int just, int wrap, 
-		 unsigned char *col1, unsigned char *col2)
+		 char *col1, char *col2)
 {
 	int bytes=0;
 
@@ -804,13 +804,13 @@ int adsi_display(unsigned char *buf, int page, int line, int just, int wrap,
 	buf[bytes++] = 0xff;
 
 	/* Primary column */
-	bytes+= ccopy(buf + bytes, col1, 20);
+	bytes+= ccopy(buf + bytes, (unsigned char *)col1, 20);
 
 	/* Delimiter */
 	buf[bytes++] = 0xff;
 	
 	/* Secondary column */
-	bytes += ccopy(buf + bytes, col2, 20);
+	bytes += ccopy(buf + bytes, (unsigned char *)col2, 20);
 
 	/* Update length */
 	buf[1] = bytes - 2;
@@ -842,7 +842,7 @@ int adsi_input_control(unsigned char *buf, int page, int line, int display, int
 
 }
 
-int adsi_input_format(unsigned char *buf, int num, int dir, int wrap, unsigned char *format1, unsigned char *format2)
+int adsi_input_format(unsigned char *buf, int num, int dir, int wrap, char *format1, char *format2)
 {
 	int bytes = 0;
 
@@ -852,10 +852,10 @@ int adsi_input_format(unsigned char *buf, int num, int dir, int wrap, unsigned c
 	buf[bytes++] = ADSI_INPUT_FORMAT;
 	bytes++;
 	buf[bytes++] = ((dir & 1) << 7) | ((wrap & 1) << 6) | (num & 0x7);
-	bytes += ccopy(buf + bytes, format1, 20);
+	bytes += ccopy(buf + bytes, (unsigned char *)format1, 20);
 	buf[bytes++] = 0xff;
 	if (format2 && strlen((char *)format2)) {
-		bytes += ccopy(buf + bytes, format2, 20);
+		bytes += ccopy(buf + bytes, (unsigned char *)format2, 20);
 	}
 	buf[1] = bytes - 2;
 	return bytes;
@@ -934,14 +934,14 @@ int adsi_channel_restore(struct ast_channel *chan)
 
 }
 
-int adsi_print(struct ast_channel *chan, unsigned char **lines, int *aligns, int voice)
+int adsi_print(struct ast_channel *chan, char **lines, int *aligns, int voice)
 {
 	unsigned char buf[4096];
 	int bytes=0;
 	int res;
 	int x;
 	for(x=0;lines[x];x++) 
-		bytes += adsi_display(buf + bytes, ADSI_INFO_PAGE, x+1, aligns[x], 0, lines[x], (unsigned char *)"");
+		bytes += adsi_display(buf + bytes, ADSI_INFO_PAGE, x+1, aligns[x], 0, lines[x], "");
 	bytes += adsi_set_line(buf + bytes, ADSI_INFO_PAGE, 1);
 	if (voice) {
 		bytes += adsi_voice_mode(buf + bytes, 0);
diff --git a/res/res_features.c b/res/res_features.c
index 35fcec02e8118090fcbf3c642b8a20c79da0d0c7..d91769db51a4d53840e16d4dffe7a7428e3e0663 100755
--- a/res/res_features.c
+++ b/res/res_features.c
@@ -248,10 +248,10 @@ static int adsi_announce_park(struct ast_channel *chan, int parkingnum)
 	int res;
 	int justify[5] = {ADSI_JUST_CENT, ADSI_JUST_CENT, ADSI_JUST_CENT, ADSI_JUST_CENT};
 	char tmp[256] = "";
-	unsigned char *message[5] = {NULL, NULL, NULL, NULL, NULL};
+	char *message[5] = {NULL, NULL, NULL, NULL, NULL};
 
 	snprintf(tmp, sizeof(tmp), "Parked on %d", parkingnum);
-	message[0] = (unsigned char *)tmp;
+	message[0] = tmp;
 	res = adsi_load_session(chan, NULL, 0, 1);
 	if (res == -1) {
 		return res;