svn_error_createf("%s", NULL, "foo\rbar\n")
should escape the control characters \r and \n rather than interpolate them
literally into the string.
This was done at one callsite already for issue #4340 a few days ago
(http://mid.gmane.org/20130327191352.GA3073@lp-shahaf.local), but should be done
in the callee instead.
As an additional motivation, "\r" in error messages causes this:
svnadmin: E160004: Could not convert ' 2\r' into a number
to be displayed as:
' into a number04: Could not convert ' 2