Re: pgsql: pgstat: Bring up pgstat in BaseInit() to fix uninitialized use o - Mailing list pgsql-committers

From Amit Kapila
Subject Re: pgsql: pgstat: Bring up pgstat in BaseInit() to fix uninitialized use o
Date
Msg-id CAA4eK1+wpLL2Q7Nqd1A1ykLmB+04QX4m4gqVm6X9w0sQYX9PcQ@mail.gmail.com
Whole thread Raw
In response to Re: pgsql: pgstat: Bring up pgstat in BaseInit() to fix uninitialized use o  (Masahiko Sawada <sawada.mshk@gmail.com>)
List pgsql-committers
On Thu, Aug 12, 2021 at 1:13 PM Masahiko Sawada <sawada.mshk@gmail.com> wrote:
>
> On Thu, Aug 12, 2021 at 3:16 PM Amit Kapila <amit.kapila16@gmail.com> wrote:
> >
> >
> > I have also tested and fix works for me. The fix works because
> > pgstat_initialize() is called before we register clean up in
> > SharedFileSetInit(). I am not sure if we need an Assert to ensure that
> > and if so how we can do that? Any suggestions?
>
> I think that the assertion added by ee3f8d3d3ae ensures that
> pgstat_initialize() is callbed before the callback for fileset cleanup
> is registered, no?
>

I think I am missing something here, can you please explain?

-- 
With Regards,
Amit Kapila.



pgsql-committers by date:

Previous
From: Dilip Kumar
Date:
Subject: Re: pgsql: pgstat: Bring up pgstat in BaseInit() to fix uninitialized use o
Next
From: Heikki Linnakangas
Date:
Subject: pgsql: Fix segfault during EvalPlanQual with mix of local and foreign p