common/Formatter: add newline to flushed output if m_pretty

This applies to json-pretty and xml-pretty modes.

Signed-off-by: Sage Weil <sage@inktank.com>
common: fix perf_counters unittests for trailing newline in m_pretty

Signed-off-by: Loic Dachary <loic@dachary.org>
Merge pull request #943 from dachary/wip-formatter-newlines

common: fix perf_counters unittests for trailing newline in m_pretty
Merge pull request #716 from ceph/wip-formatter-newlines

common/Formatter: add newline to flushed output if m_pretty