processing: Fix use-after-free
The buffer holding the last output line got freed when it was converted into a pointer and then returned.
This fixes that while also dropping the check for valid UTF-8 in the string returned by the post-processor. Let the next part of the pipeline deal with it.