Re: pgsql: Handle numeric overflow in numeric_minmax_multi_ops

From: Tomas Vondra <tomas(at)vondra(dot)me>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Tomas Vondra <tomas(dot)vondra(at)postgresql(dot)org>
Cc: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: Re: pgsql: Handle numeric overflow in numeric_minmax_multi_ops
Date: 2026-11-12 16:33:19
Message-ID: c6b81733-b5e8-472f-862e-2e39e67f85b9@vondra.me
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers


On 11/6/26 04:07, Tom Lane wrote:
> Tomas Vondra <tomas(dot)vondra(at)postgresql(dot)org> writes:
>> Handle numeric overflow in numeric_minmax_multi_ops
>
> Hi, this commit is making a few buildfarm members unhappy,
> eg at [1]:
>
> In file included from brin_minmax_multi.c:72:0:
> brin_minmax_multi.c: In function \342\200\230brin_minmax_multi_distance_numeric\342\200\231:
> ../../../../src/include/nodes/miscnodes.h:54:15: warning: the comparison will always evaluate as \342\200\230true\342\200\231 for the address of \342\200\230escontext\342\200\231 will never be NULL [-Waddress]
> ((escontext) != NULL && IsA(escontext, ErrorSaveContext) && \\
> ^
> brin_minmax_multi.c:2070:6: note: in expansion of macro \342\200\230SOFT_ERROR_OCCURRED\342\200\231
> if (SOFT_ERROR_OCCURRED(&escontext))
> ^~~~~~~~~~~~~~~~~~~
>
> We have seen this before, and the way to silence it is
>
> - if (SOFT_ERROR_OCCURRED(&escontext))
> + if (escontext.error_occurred)
>
> regards, tom lane
>

Uh, I completely missed this report, and only noticed it now when I saw
the commit fixing it. Apologies and thanks for taking care of it!

Thanks

--
Tomas Vondra

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2026-11-12 16:48:13 pgsql: plpython: share the SD dictionary across cache entries of a func
Previous Message Tom Lane 2026-11-12 16:06:55 pgsql: Silence compiler warnings about SOFT_ERROR_OCCURRED usage.