Hi,
I noticed an issue with bootlogd where lines beginning with a tab character are not written to the log file. In bootlogd.c I'm looking at lines 389 through 393... this snippet:
--snip--
case '\t':
line.pos += (line.pos / 8 + 1) * 8;
if (line.pos >= (int)sizeof(line.buf))
line.pos = sizeof(line.buf) - 1;
break;
--snip--
So when the character is a tab, we're advancing line.pos and we start writing the output to line.buf after this, but the problem is when we write the buffer to the file (fprintf() in line 412) we get nothing printed to the file since line.buf + 0 .. 7 is \0.
I don't understand the intention of this block of code, but I assume its so we don't print a tab character to the log file. Perhaps instead just print spaces (8 or 4 or X) to the file in-place of tabs?
Any help would be greatly appreciated.
Thanks,
Marc