Index: trunk/Ohana/src/libfits/matrix/F_load_M.c
===================================================================
--- trunk/Ohana/src/libfits/matrix/F_load_M.c	(revision 5395)
+++ trunk/Ohana/src/libfits/matrix/F_load_M.c	(revision 5851)
@@ -34,12 +34,12 @@
   perpix = abs(header[0].bitpix) / 8;
   if (perpix > 1) {
-    byte0 = (char *) matrix[0].buffer;
-    byte1 = (char *) matrix[0].buffer + 1;
-    byte2 = (char *) matrix[0].buffer + 2;
-    byte3 = (char *) matrix[0].buffer + 3;
-    byte4 = (char *) matrix[0].buffer + 4;
-    byte5 = (char *) matrix[0].buffer + 5;
-    byte6 = (char *) matrix[0].buffer + 6;
-    byte7 = (char *) matrix[0].buffer + 7;
+    byte0 = (unsigned char *) matrix[0].buffer;
+    byte1 = (unsigned char *) matrix[0].buffer + 1;
+    byte2 = (unsigned char *) matrix[0].buffer + 2;
+    byte3 = (unsigned char *) matrix[0].buffer + 3;
+    byte4 = (unsigned char *) matrix[0].buffer + 4;
+    byte5 = (unsigned char *) matrix[0].buffer + 5;
+    byte6 = (unsigned char *) matrix[0].buffer + 6;
+    byte7 = (unsigned char *) matrix[0].buffer + 7;
     if (perpix == 2) {
       for (i = 0; i < nbytes; i+=2, byte0 += 2, byte1 += 2) {
Index: trunk/Ohana/src/libfits/matrix/F_read_portion.c
===================================================================
--- trunk/Ohana/src/libfits/matrix/F_read_portion.c	(revision 5395)
+++ trunk/Ohana/src/libfits/matrix/F_read_portion.c	(revision 5851)
@@ -52,12 +52,12 @@
   perpix = abs(header.bitpix) / 8;
   if (perpix > 1) {
-    byte0 = (char *) matrix[0].buffer;
-    byte1 = (char *) matrix[0].buffer + 1;
-    byte2 = (char *) matrix[0].buffer + 2;
-    byte3 = (char *) matrix[0].buffer + 3;
-    byte4 = (char *) matrix[0].buffer + 4;
-    byte5 = (char *) matrix[0].buffer + 5;
-    byte6 = (char *) matrix[0].buffer + 6;
-    byte7 = (char *) matrix[0].buffer + 7;
+    byte0 = (unsigned char *) matrix[0].buffer;
+    byte1 = (unsigned char *) matrix[0].buffer + 1;
+    byte2 = (unsigned char *) matrix[0].buffer + 2;
+    byte3 = (unsigned char *) matrix[0].buffer + 3;
+    byte4 = (unsigned char *) matrix[0].buffer + 4;
+    byte5 = (unsigned char *) matrix[0].buffer + 5;
+    byte6 = (unsigned char *) matrix[0].buffer + 6;
+    byte7 = (unsigned char *) matrix[0].buffer + 7;
     if (perpix == 2) {
       for (i = 0; i < nbytes; i+=2, byte0 += 2, byte1 += 2) {
Index: trunk/Ohana/src/libfits/matrix/F_read_segment.c
===================================================================
--- trunk/Ohana/src/libfits/matrix/F_read_segment.c	(revision 5395)
+++ trunk/Ohana/src/libfits/matrix/F_read_segment.c	(revision 5851)
@@ -84,12 +84,12 @@
   perpix = abs(header.bitpix) / 8;
   if (perpix > 1) {
-    byte0 = (char *) matrix[0].buffer;
-    byte1 = (char *) matrix[0].buffer + 1;
-    byte2 = (char *) matrix[0].buffer + 2;
-    byte3 = (char *) matrix[0].buffer + 3;
-    byte4 = (char *) matrix[0].buffer + 4;
-    byte5 = (char *) matrix[0].buffer + 5;
-    byte6 = (char *) matrix[0].buffer + 6;
-    byte7 = (char *) matrix[0].buffer + 7;
+    byte0 = (unsigned char *) matrix[0].buffer;
+    byte1 = (unsigned char *) matrix[0].buffer + 1;
+    byte2 = (unsigned char *) matrix[0].buffer + 2;
+    byte3 = (unsigned char *) matrix[0].buffer + 3;
+    byte4 = (unsigned char *) matrix[0].buffer + 4;
+    byte5 = (unsigned char *) matrix[0].buffer + 5;
+    byte6 = (unsigned char *) matrix[0].buffer + 6;
+    byte7 = (unsigned char *) matrix[0].buffer + 7;
     if (perpix == 2) {
       for (i = 0; i < nbytes; i+=2, byte0 += 2, byte1 += 2) {
Index: trunk/Ohana/src/libfits/matrix/F_write_M.c
===================================================================
--- trunk/Ohana/src/libfits/matrix/F_write_M.c	(revision 5395)
+++ trunk/Ohana/src/libfits/matrix/F_write_M.c	(revision 5851)
@@ -41,12 +41,12 @@
   perpix = abs(matrix[0].bitpix) / 8;
   if (perpix > 1) {
-    byte0 = (char *) matrix[0].buffer;
-    byte1 = (char *) matrix[0].buffer + 1;
-    byte2 = (char *) matrix[0].buffer + 2;
-    byte3 = (char *) matrix[0].buffer + 3;
-    byte4 = (char *) matrix[0].buffer + 4;
-    byte5 = (char *) matrix[0].buffer + 5;
-    byte6 = (char *) matrix[0].buffer + 6;
-    byte7 = (char *) matrix[0].buffer + 7;
+    byte0 = (unsigned char *) matrix[0].buffer;
+    byte1 = (unsigned char *) matrix[0].buffer + 1;
+    byte2 = (unsigned char *) matrix[0].buffer + 2;
+    byte3 = (unsigned char *) matrix[0].buffer + 3;
+    byte4 = (unsigned char *) matrix[0].buffer + 4;
+    byte5 = (unsigned char *) matrix[0].buffer + 5;
+    byte6 = (unsigned char *) matrix[0].buffer + 6;
+    byte7 = (unsigned char *) matrix[0].buffer + 7;
     if (perpix == 2) {
       for (i = 0; i < nbytes; i+=2, byte0 += 2, byte1 += 2) {
@@ -93,12 +93,12 @@
   perpix = abs(matrix[0].bitpix) / 8;
   if (perpix > 1) {
-    byte0 = (char *) matrix[0].buffer;
-    byte1 = (char *) matrix[0].buffer + 1;
-    byte2 = (char *) matrix[0].buffer + 2;
-    byte3 = (char *) matrix[0].buffer + 3;
-    byte4 = (char *) matrix[0].buffer + 4;
-    byte5 = (char *) matrix[0].buffer + 5;
-    byte6 = (char *) matrix[0].buffer + 6;
-    byte7 = (char *) matrix[0].buffer + 7;
+    byte0 = (unsigned char *) matrix[0].buffer;
+    byte1 = (unsigned char *) matrix[0].buffer + 1;
+    byte2 = (unsigned char *) matrix[0].buffer + 2;
+    byte3 = (unsigned char *) matrix[0].buffer + 3;
+    byte4 = (unsigned char *) matrix[0].buffer + 4;
+    byte5 = (unsigned char *) matrix[0].buffer + 5;
+    byte6 = (unsigned char *) matrix[0].buffer + 6;
+    byte7 = (unsigned char *) matrix[0].buffer + 7;
     if (perpix == 2) {
       for (i = 0; i < nbytes; i+=2, byte0 += 2, byte1 += 2) {
