Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int my_spec(va_list p)
- {
- char *str;
- int i;
- i = 0;
- str = va_arg(p, char *);
- while (*str)
- {
- if (!is_printable_char(*str))
- {
- my_putstr("\\0");
- i += 2;
- i += my_putnbr_base(*str, "01234567");
- }
- else
- {
- my_putchar(*str);
- i++;
- }
- str++;
- }
- return (i);
- }
Advertisement
Add Comment
Please, Sign In to add comment