Patch attached. Some kinds of emit log hooks might find it useful toalso compute the log_line_prefix.
Regards, Jeff Davis