Re: gcc -Wclobbered in PostgresMain

Поиск
Список
Период
Сортировка
От Sergey Shinderuk
Тема Re: gcc -Wclobbered in PostgresMain
Дата
Msg-id 1f8a7f29-b526-db35-5584-a078ca20c8e2@postgrespro.ru
обсуждение исходный текст
Ответ на Re: gcc -Wclobbered in PostgresMain  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: gcc -Wclobbered in PostgresMain  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Hello, Tom,


On 08.07.2023 18:11, Tom Lane wrote:
> What we ought to be doing is resetting these two flags
> after the disable_all_timeouts call.


Oops, I missed that.


> Having done that, it wouldn't really be necessary to mark these
> as volatile.  I kept that marking anyway for consistency with
> send_ready_for_query, but perhaps we shouldn't?


I don't know. Maybe marking them volatile is more future proof. Not sure.


>> I also moved firstchar's declaration inside the loop where it's used, to
>> make it clear that this variable needn't be volatile and is not
>> preserved after longjmp().
> 
> Good idea, but then why not the same for input_message?  It's fully
> reinitialized each time through the loop, too.


Yeah, that's better.


> In short, something like the attached, except I'm not totally sold
> on changing the volatility of the timeout flags.

Looks good to me.


Thank you.

-- 
Sergey Shinderuk        https://postgrespro.com/




В списке pgsql-hackers по дате отправления:

Предыдущее
От: Daniel Gustafsson
Дата:
Сообщение: Re: Some revises in adding sorting path
Следующее
От: Amit Kapila
Дата:
Сообщение: Re: [Patch] Use *other* indexes on the subscriber when REPLICA IDENTITY is FULL