normalizes newlines in logging output