Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
logsink: fix multiple issues with LogSink::ToString()
1. Initializing std::ostringstream with a string makes no sense, as the string becomes an initial value of an underlying buffer; seek-to-end is not performed, so the initial value gets completely overwritten by subsequent writing. 2. Flag `log_year_in_prefix` should be considered, as if formatting a regular logging message. 3. Writing a buffer to std::ostream is better expressed with write(s,n).
- Loading branch information