Re: Small miscellaneus fixes (Part II)

2023-01-17 Thread Ranier Vilela
Em ter., 17 de jan. de 2023 às 04:37, John Naylor < john.nay...@enterprisedb.com> escreveu: > > On Mon, Jan 16, 2023 at 1:28 PM John Naylor > wrote: > > > > > > I wrote: > > > ...but arguably the earlier check is close enough that it's silly to > assert in the "else" branch, and I'd be okay with

Re: Small miscellaneus fixes (Part II)

2023-01-16 Thread John Naylor
On Mon, Jan 16, 2023 at 1:28 PM John Naylor wrote: > > > I wrote: > > ...but arguably the earlier check is close enough that it's silly to assert in the "else" branch, and I'd be okay with just nuking those lines. Another thing that caught my attention is the assumption that unsetting a bit is so

Re: Small miscellaneus fixes (Part II)

2023-01-16 Thread Ranier Vilela
Em seg., 16 de jan. de 2023 às 03:28, John Naylor < john.nay...@enterprisedb.com> escreveu: > > I wrote: > > ...but arguably the earlier check is close enough that it's silly to > assert in the "else" branch, and I'd be okay with just nuking those lines. > Another thing that caught my attention

Re: Small miscellaneus fixes (Part II)

2023-01-15 Thread John Naylor
I wrote: > ...but arguably the earlier check is close enough that it's silly to assert in the "else" branch, and I'd be okay with just nuking those lines. Another thing that caught my attention is the assumption that unsetting a bit is so expensive that we have to first check if it's set, so we

Re: Small miscellaneus fixes (Part II)

2023-01-11 Thread John Naylor
On Thu, Jan 12, 2023 at 12:34 PM Justin Pryzby wrote: > > On Thu, Jan 12, 2023 at 12:15:24PM +0700, John Naylor wrote: > > On Fri, Dec 23, 2022 at 8:08 AM Justin Pryzby wrote: > > > > > Makes sense now (in your first message, you said that the problem was > > > with "sign", and the patch didn't

Re: Small miscellaneus fixes (Part II)

2023-01-11 Thread Justin Pryzby
On Thu, Jan 12, 2023 at 12:15:24PM +0700, John Naylor wrote: > On Fri, Dec 23, 2022 at 8:08 AM Justin Pryzby wrote: > > > Makes sense now (in your first message, you said that the problem was > > with "sign", and the patch didn't address the actual problem in > > IS_PLUS()). > > > > One can look

Re: Small miscellaneus fixes (Part II)

2023-01-11 Thread John Naylor
On Fri, Dec 23, 2022 at 8:08 AM Justin Pryzby wrote: > Makes sense now (in your first message, you said that the problem was > with "sign", and the patch didn't address the actual problem in > IS_PLUS()). > > One can look and find that the unreachable code was introduced at > 7a3e7b64a. > > With

Re: Small miscellaneus fixes (Part II)

2022-12-22 Thread Justin Pryzby
On Thu, Dec 22, 2022 at 02:29:11PM -0300, Ranier Vilela wrote: > Em ter., 20 de dez. de 2022 às 21:51, Justin Pryzby > escreveu: > > > On Fri, Nov 25, 2022 at 06:27:04PM -0300, Ranier Vilela wrote: > > > 5. Use boolean operator with boolean operands > > > (b/src/backend/commands/tablecmds.c) >

Re: Small miscellaneus fixes (Part II)

2022-12-22 Thread Ranier Vilela
Em ter., 20 de dez. de 2022 às 21:51, Justin Pryzby escreveu: > On Fri, Nov 25, 2022 at 06:27:04PM -0300, Ranier Vilela wrote: > > 5. Use boolean operator with boolean operands > > (b/src/backend/commands/tablecmds.c) > > tablecmds.c: right. Since 074c5cfbf > > pg_dump.c: right. Since

Re: Small miscellaneus fixes (Part II)

2022-12-22 Thread Ranier Vilela
Em qua., 21 de dez. de 2022 às 04:10, Michael Paquier escreveu: > On Tue, Dec 20, 2022 at 06:51:34PM -0600, Justin Pryzby wrote: > > On Fri, Nov 25, 2022 at 06:27:04PM -0300, Ranier Vilela wrote: > > > 5. Use boolean operator with boolean operands > > > (b/src/backend/commands/tablecmds.c) > > >

Re: Small miscellaneus fixes (Part II)

2022-12-21 Thread Ranier Vilela
Thanks for looking at this. Em ter., 20 de dez. de 2022 às 21:51, Justin Pryzby escreveu: > On Fri, Nov 25, 2022 at 06:27:04PM -0300, Ranier Vilela wrote: > > 5. Use boolean operator with boolean operands > > (b/src/backend/commands/tablecmds.c) > > tablecmds.c: right. Since 074c5cfbf > >

Re: Small miscellaneus fixes (Part II)

2022-12-20 Thread Michael Paquier
On Tue, Dec 20, 2022 at 06:51:34PM -0600, Justin Pryzby wrote: > On Fri, Nov 25, 2022 at 06:27:04PM -0300, Ranier Vilela wrote: > > 5. Use boolean operator with boolean operands > > (b/src/backend/commands/tablecmds.c) > > tablecmds.c: right. Since 074c5cfbf Most of this does not seem to be

Re: Small miscellaneus fixes (Part II)

2022-12-20 Thread Justin Pryzby
On Fri, Nov 25, 2022 at 06:27:04PM -0300, Ranier Vilela wrote: > 5. Use boolean operator with boolean operands > (b/src/backend/commands/tablecmds.c) tablecmds.c: right. Since 074c5cfbf pg_dump.c: right. Since b08dee24a > 4. Fix dead code (src/backend/utils/adt/formatting.c) > Np->sign ==

Small miscellaneus fixes (Part II)

2022-11-25 Thread Ranier Vilela
Hi. There another assorted fixes to the head branch. 1. Avoid useless pointer increment (src/backend/utils/activity/pgstat_shmem.c) The pointer *p, is used in creation dsa memory, not p + MAXALIGN(pgstat_dsa_init_size()). 2. Discard result unused (src/backend/access/transam/xlogrecovery.c)