On Thu, Oct 20, 2016 at 04:42:13AM -0400, Ted Unangst wrote: > Otto Moerbeek wrote: > > That is certainly not correct: snprintf and friends return the length as > > it would have been if an infinite buffer was passed in. > > So the strlen should stay. I'll make a new diff soon though with the > > error checking, although it might be overkill for this case. > > I think we're getting a little weird here. The circumstances under which > snprintf can return -1 are quite limited.
it can only happen on encoding errors, right? These are not relevant in this case. -0tto