Move newline printing to bt_printf macro, dont sprintf timestamp

Use memcpy to copy the timestamp string, and move newline printing into the
bt_printf macro.

This patch also includes a subtle work-around to an annoying bug. By adding a
space after every newline (now appended in the macro), we work around a bug
where either libz or some location in my code that I haven't been able to find
overwrites the last byte with a 0. I swear it's a bug in libz...

Signed-off-by: Jeremy C. Andrus <jeremya@cs.columbia.edu>
Don't call gzflush as often, use an extra gzwrite

the extra gzwrite is a hack-ish way to work around a bug where the previously
written character is overwritten by a zero. I swear this is in libz.

Occasionally you will see larger chunks of text overwritten (seemingly
haphazardly), but these are fortunately rare and can be worked around
during post-processing.

Signed-off-by: Jeremy C. Andrus <jeremya@cs.columbia.edu>