]> git.ipfire.org Git - thirdparty/postgresql.git/commit
Fix tracing of BackendKeyData and CancelRequest
authorHeikki Linnakangas <heikki.linnakangas@iki.fi>
Fri, 3 Jul 2026 11:57:35 +0000 (14:57 +0300)
committerHeikki Linnakangas <heikki.linnakangas@iki.fi>
Fri, 3 Jul 2026 11:59:56 +0000 (14:59 +0300)
commit0766bc57e9f94e5321e6ea4cb49db430224b2e60
tree3a7c15b0f1cec26f8dd44546557fc4bcb16120ed
parentfb284f2f9bdb9dd5e866132f7d0b8eeaa972e521
Fix tracing of BackendKeyData and CancelRequest

BackendKeyData length was increased from 4 bytes to a variable-length
length (up to 256 bytes) in a460251f0a. However, pqTrace still traces
it as a 4 bytes key, leading to a "mismatched message length" warning
message. The same issue impacts the tracing of CancelRequest.

This patch fixes the issue by using pqTraceOutputNchar instead of
pqTraceOutputInt32 in both cases.

Author: Anthonin Bonnefoy <anthonin.bonnefoy@datadoghq.com>
Discussion: https://www.postgresql.org/message-id/CAO6_Xqo6gTv9=76H=k2qDRFU+KHuBiY2S=bQynEr6J8gS7L6xA@mail.gmail.com
Backpatch-through: 18
src/interfaces/libpq/fe-trace.c