summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Utilities/cmtar/compat/snprintf.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/Utilities/cmtar/compat/snprintf.c b/Utilities/cmtar/compat/snprintf.c
index 94e420a..26a203e 100644
--- a/Utilities/cmtar/compat/snprintf.c
+++ b/Utilities/cmtar/compat/snprintf.c
@@ -311,7 +311,7 @@ static void dopr (char *buffer, size_t maxlen, const char *format, va_list args)
fvalue = va_arg (args, double);
break;
case 'c':
- dopr_outch (buffer, &currlen, maxlen, va_arg (args, int));
+ dopr_outch (buffer, &currlen, maxlen, (char)(va_arg (args, int)));
break;
case 's':
strvalue = va_arg (args, char *);
@@ -478,7 +478,7 @@ static void fmtint (char *buffer, size_t *currlen, size_t maxlen,
/* Sign */
if (signvalue)
- dopr_outch (buffer, currlen, maxlen, signvalue);
+ dopr_outch (buffer, currlen, maxlen, (char)signvalue);
/* Zeros */
if (zpadlen > 0)
@@ -629,7 +629,7 @@ static void fmtfp (char *buffer, size_t *currlen, size_t maxlen,
{
if (signvalue)
{
- dopr_outch (buffer, currlen, maxlen, signvalue);
+ dopr_outch (buffer, currlen, maxlen, (char)signvalue);
--padlen;
signvalue = 0;
}
@@ -645,7 +645,7 @@ static void fmtfp (char *buffer, size_t *currlen, size_t maxlen,
--padlen;
}
if (signvalue)
- dopr_outch (buffer, currlen, maxlen, signvalue);
+ dopr_outch (buffer, currlen, maxlen, (char)signvalue);
while (iplace > 0)
dopr_outch (buffer, currlen, maxlen, iconvert[--iplace]);