pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Noah Misch <noah@leadboat.com>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Test ECPG decadd(), decdiv(), decmul(), and decsub() for risnull
Date: Sat, 25 Jan 2025 19:29:54 +0000
Message-ID: <E1tblqr-003VLg-Vo@gemulon.postgresql.org> (raw)

Test ECPG decadd(), decdiv(), decmul(), and decsub() for risnull() input.

Since commit 757fb0e5a9a61ac8d3a67e334faeea6dc0084b3f, these
Informix-compat functions return 0 without changing the output
parameter.  Initialize the output parameter before the test call, making
that obvious.  Before this, the expected test output has been depending
on freed stack memory.  "gcc -ftrivial-auto-var-init=pattern" revealed
that.  Back-patch to v13 (all supported versions).

Discussion: https://postgr.es/m/20250106192748.cf.nmisch@google.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/7819a25cd101b574f5422edb00fe3376fbb646da

Modified Files
--------------
.../ecpg/test/compat_informix/dec_test.pgc         |  10 +
.../ecpg/test/expected/compat_informix-dec_test.c  |  10 +
.../test/expected/compat_informix-dec_test.stdout  | 232 ++++++++++-----------
3 files changed, 136 insertions(+), 116 deletions(-)



view thread (6+ messages)  latest in thread

Message-ID: <E1tblqr-003VLg-Vo@gemulon.postgresql.org>
Permalink:  ../E1tblqr-003VLg-Vo@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1tblqr-003VLg-Vo@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: noah@leadboat.com, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Test ECPG decadd(), decdiv(), decmul(), and decsub() for risnull
  In-Reply-To: <E1tblqr-003VLg-Vo@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox