1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 20:27:45 +00:00

more: Don't printf(string), printf("%s", string)!

Found by PVS-Studio.
This commit is contained in:
Andreas Kling 2019-08-01 11:39:41 +02:00
parent cbfa211988
commit 4271bebbef

View file

@ -34,7 +34,7 @@ int main(int argc, char** argv)
auto* str = fgets(buffer, sizeof(buffer), stdin);
if (!str)
break;
printf(str);
printf("%s", str);
++lines_printed;
if ((lines_printed % (ws.ws_row - 1)) == 0) {
wait_for_key();