diff options
Diffstat (limited to 'convert_str.c')
| -rw-r--r-- | convert_str.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/convert_str.c b/convert_str.c index dbdf01e..3cea2dc 100644 --- a/convert_str.c +++ b/convert_str.c @@ -7,7 +7,7 @@ char *convert_str(va_list ap, t_pformat *pformat) str = str == NULL ? ft_strdup("(null)") : ft_strdup(str); - if (pformat->precision != -1 && pformat->precision < ft_strlen(str)) + if (pformat->precision != -1 && pformat->precision < (int)ft_strlen(str)) str[pformat->precision] = '\0'; str = handle_padding(pformat, str); |
