David Rowley <david.rowley@2ndquadrant.com> writes:
> On Tue, 8 Oct 2019 at 19:46, Joe Nelson <joe@begriffs.com> wrote:
>> David Rowley wrote:
>>> The translation string here must be consistent over all platforms. I
>>> think this will cause issues if the translation string uses %ld and
>>> the platform requires %lld?
>> A very good and subtle point. I'll change it to %lld so that a single
>> format string will work everywhere.
> The way to do this is to make a temp buffer and snprintf into that
> buffer then use %s.
We have done it that way in the past, but it was mainly because we
couldn't be sure that snprintf was on board with %lld. I think that
the new consensus is that forcing use of "long long" is a less messy
solution (unless you need to back-patch the code). See commit
6a1cd8b92 for recent precedent.
regards, tom lane