Parses a log entry of the form LOG <level> <timestamp> <message> where the
level is in the range [0, 4]. If the entry is not of that form, take the whole
entry to be the message. Null characters in the entry are replaced by
newlines.

With the classic streaming API, we did not distinguish between a message
that came through the logging infrastructure and one that came through stderr
or logservice.write but had been written to look like it came from logging.

Note that this code does not provide 100% accuracy with the old stream
service. In the past, they could have written: