Skip to content
Snippets Groups Projects
Commit b14619ba authored by Heinrich Schuchardt's avatar Heinrich Schuchardt Committed by Tom Rini
Browse files

tools/file2include: avoid incorrect comments


Avoid creating incorrect comments like /* ...*/... */ by printing
'.' instead of '*' inside comments.

Signed-off-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
parent 4a8e7295
No related branches found
No related tags found
No related merge requests found
......@@ -84,7 +84,7 @@ int main(int argc, char *argv[])
printf("\\x%02x", buf[j]);
printf("\"}, /* ");
for (j = i; j < i + BLOCK_SIZE && j < count; ++j) {
if (buf[j] >= 0x20 && buf[j] <= 0x7e)
if (buf[j] != '*' && buf[j] >= 0x20 && buf[j] <= 0x7e)
printf("%c", buf[j]);
else
printf(".");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment