`format` considers a zero-length result (e.g. from `format("%s", "")`)
to be a fatal error. The check originates from
0a7cea64 where it was
appropriate but become incorrect later when refactoring the original
`x_asprintf2` function to `format`.
I can’t find any call to `format` that would trigger this edge case, but
let’s remove the erroneous check anyway.
Related to #568.
}
va_end(ap);
- if (!*ptr) {
- fatal("Internal error in format");
- }
return ptr;
}