printf: support escaping '%' with '%%'. See printf(1p) EXAMPLES section.

This commit is contained in:
pranomostro 2016-06-25 19:11:09 +02:00 committed by sin
parent 11d8e91042
commit 229d7cc89a
1 changed files with 3 additions and 1 deletions

View File

@ -103,8 +103,10 @@ main(int argc, char *argv[])
arg = "";
cooldown = 1;
}
} else
} else {
putchar('%');
continue;
}
switch (format[i]) {
case 'b':