Re: pgsql: pg_upgrade: Fix inconsistency in memory freeing

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: Jeff Davis <pgsql(at)j-davis(dot)com>
Cc: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: Re: pgsql: pg_upgrade: Fix inconsistency in memory freeing
Date: 2025-04-01 23:25:24
Message-ID: 72173298-8CF2-489E-9549-27A224D30A3F@paquier.xyz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

On Mar 31, 2025, at 3:12, Jeff Davis <pgsql(at)j-davis(dot)com> wrote:
> Why pg_strdup() the "NULL" at all in that case? Usually I see that done
> so that there doesn't need to be a conditional when freeing, but here
> there's a conditional anyway.
>
> Perhaps something like the attached?

This would work for me as well. I’m ok to take care of it at the beginning of next week, based on your suggestion.
--
Michael

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Melanie Plageman 2025-04-01 23:54:08 pgsql: aio: Add errcontext for processing I/Os for another backend
Previous Message David Rowley 2025-04-01 22:58:51 pgsql: Fix planner's failure to identify multiple hashable ScalarArrayO