Re: Numeric multiplication overflow errors
Dean Rasheed <dean.a.rasheed@gmail.com>
From: Dean Rasheed <dean.a.rasheed@gmail.com>
To: David Rowley <dgrowleyml@gmail.com>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2021-07-05T10:04:29Z
Lists: pgsql-hackers
Attachments
- numeric-mul-overflow-v3.patch (text/x-patch) patch v3
On Sun, 4 Jul 2021 at 09:43, David Rowley <dgrowleyml@gmail.com> wrote: > > On Sat, 3 Jul 2021 at 11:04, Dean Rasheed <dean.a.rasheed@gmail.com> wrote: > > Thinking about this more, I think it's best not to risk back-patching. > > It *might* be safe, but it's difficult to really be sure of that. The > > bug itself is pretty unlikely to ever happen in practice, hence the > > lack of prior complaints, and in fact I only found it by an > > examination of the code. So it doesn't seem to be worth the risk. > > That seems like good logic to me. Perhaps we can reconsider that > decision if users complain about it. Thanks. Pushed to master only. I think the other part (avoiding overflows in numeric_mul) is fairly straightforward and uncontentious, so barring objections, I'll push and back-patch it in a couple of days or so. Regards, Dean
Commits
-
Fix numeric_mul() overflow due to too many digits after decimal point.
- f8abf6944b12 9.6.23 landed
- 54a0ec1bd6d5 10.18 landed
- 5763ef42c187 11.13 landed
- 357b66ef9470 12.8 landed
- f23a9b8a49af 13.4 landed
- 06883d58ff29 14.0 landed
- e7fc488ad67c 15.0 landed
-
Prevent numeric overflows in parallel numeric aggregates.
- f025f2390e13 15.0 landed