decided where to init the indexes

This commit is contained in:
LinlyBoi
2023-08-22 14:04:54 +03:00
parent 4b798e200c
commit 3174bc405f

View File

@@ -24,6 +24,8 @@ int _printf(const char *format, ...)
if (!format) /* No string. No laundry */ if (!format) /* No string. No laundry */
return (0); return (0);
buff_idx = 0;
fmt_idx = 0;
while (*(format + fmt_idx)) while (*(format + fmt_idx))
{ {
if ((*(format + fmt_idx) == '%') && (*(format + fmt_idx + 1))) if ((*(format + fmt_idx) == '%') && (*(format + fmt_idx + 1)))