public inbox for [email protected]  
help / color / mirror / Atom feed
From: Andrew Dunstan <[email protected]>
To: Mahendra Singh Thalor <[email protected]>
To: Peter Eisentraut <[email protected]>
Cc: jian he <[email protected]>
Cc: tushar <[email protected]>
Cc: Vaibhav Dalvi <[email protected]>
Cc: [email protected]
Subject: Re: Non-text mode for pg_dumpall
Date: Wed, 4 Mar 2026 15:54:48 -0500
Message-ID: <[email protected]> (raw)
In-Reply-To: <CAKYtNAp+SBSVENOtvEqpAcZCeQZhNZFU005Jy5-eP+2kC-3ryA@mail.gmail.com>
References: <[email protected]>
	<CAKYtNArc3j8Akb+nB1QyJLKic7ej7vKZqKnv_mbB+iQAJRzLnA@mail.gmail.com>
	<CAC6VRoat6NPcS6vfGrPrwaQB3G1JHLSqDeAkf1AJ7npWrwhnUQ@mail.gmail.com>
	<CAKYtNAp=TFEZWQbTRZso3kNaD9BH=-JPNQ30mT60cJN_04hEog@mail.gmail.com>
	<[email protected]>
	<CAKYtNAq73_UeL4-0wgu9rawctHdS2zhpzWtqVuOChCS3M+2Ymg@mail.gmail.com>
	<CACJufxFs9NXXTeb78i2MD+pnZootayAtiGcNHNeU35SmQgMjbA@mail.gmail.com>
	<[email protected]>
	<CACJufxEnmJ8otfmN7Kp110Wqi=M4YE0-zn-W6SK+eTpWuZw_fg@mail.gmail.com>
	<CAKYtNAqxjQMLVPfz6XESqszhxZKgigi7UEBzBhz_Wj_Bnasdag@mail.gmail.com>
	<[email protected]>
	<CACJufxE-zJiBAaZABtJBJr8FZdj=xP5adf_excmu9S6Op=KpLA@mail.gmail.com>
	<[email protected]>
	<[email protected]>
	<CAKYtNAp+SBSVENOtvEqpAcZCeQZhNZFU005Jy5-eP+2kC-3ryA@mail.gmail.com>


On 2026-03-03 Tu 6:17 AM, Mahendra Singh Thalor wrote:
> On Tue, 3 Mar 2026 at 14:55, Peter Eisentraut <[email protected]> wrote:
>> I noticed this cast in the committed code:
>>
>>> + num_total_db = get_dbname_oid_list_from_mfile((char *) inputFileSpec,
>>> &dbname_oid_list);
>> The cast drops the const qualifier from inputFileSpec.
>> get_dbname_oid_list_from_mfile() writes into the space pointed to by its
>> argument, so it's really not "const".  (And inputFileSpec points into
>> argv, so this ends up writing directly into argv.)
>>
>> Please see if you can clean this up.  It might be best if
>> get_dbname_oid_list_from_mfile() made a copy of its argument that it can
>> write into, and then the argument can be "const".
>>
> Thanks Peter.
>
> Here, I am attaching a patch to fix this issue.


Pushed with a slight tweak.


cheers


andrew

--
Andrew Dunstan
EDB: https://www.enterprisedb.com






view thread (111+ messages)  latest in thread

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: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: Non-text mode for pg_dumpall
  In-Reply-To: <[email protected]>

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

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