changeset 22310:c68a115303f7

(doprnt1): Fix char signedness mismatches.
author Karl Heuer <kwzh@gnu.org>
date Mon, 01 Jun 1998 03:32:00 +0000
parents 41baef80bbbc
children 599c0971ae49
files src/doprnt.c
diffstat 1 files changed, 6 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/src/doprnt.c	Mon Jun 01 03:12:04 1998 +0000
+++ b/src/doprnt.c	Mon Jun 01 03:32:00 1998 +0000
@@ -108,7 +108,7 @@
   char *big_buffer = 0;
 
   register int tem;
-  char *string;
+  unsigned char *string;
   char fixed_buffer[20];	/* Default buffer for small formatting. */
   char *fmtcpy;
   int minlen;
@@ -135,7 +135,7 @@
 
 	  fmt++;
 	  /* Copy this one %-spec into fmtcpy.  */
-	  string = fmtcpy;
+	  string = (unsigned char *)fmtcpy;
 	  *string++ = '%';
 	  while (1)
 	    {
@@ -207,7 +207,7 @@
 		abort ();
 	      sprintf (sprintf_buffer, fmtcpy, args[cnt++]);
 	      /* Now copy into final output, truncating as nec.  */
-	      string = sprintf_buffer;
+	      string = (unsigned char *)sprintf_buffer;
 	      goto doit;
 
 	    case 'f':
@@ -221,7 +221,7 @@
 		u.half[1] = args[cnt++];
 		sprintf (sprintf_buffer, fmtcpy, u.d);
 		/* Now copy into final output, truncating as nec.  */
-		string = sprintf_buffer;
+		string = (unsigned char *)sprintf_buffer;
 		goto doit;
 	      }
 
@@ -234,13 +234,13 @@
 		minlen = atoi (&fmtcpy[1]);
 	      if (lispstrings)
 		{
-		  string = (char *) ((struct Lisp_String *)args[cnt])->data;
+		  string = ((struct Lisp_String *)args[cnt])->data;
 		  tem = ((struct Lisp_String *)args[cnt])->size;
 		  cnt++;
 		}
 	      else
 		{
-		  string = args[cnt++];
+		  string = (unsigned char *)args[cnt++];
 		  tem = strlen (string);
 		}
 	      width = strwidth (string, tem);