Refactor: libcrmcommon: Remove insert_spaces() static helper
pcmkxml2text() calls all the functions that currently call
insert_spaces(). It's straightforward to NULL-check buffer and ensure
depth is nonnegative in pcmkxml2text(). Then the insert_spaces()
helper only saves us about three lines per call. At that point it seems
cleaner to defunctionize it and use loops with an explicitly calculated
number of spaces.
This may trivially improve performance (fewer redundant checks) and code
size (insert_spaces() was inline), but this is mostly for readability.
Signed-off-by: Reid Wahl <nrwahl@protonmail.com>