Re: GCC warning in back branches

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: GCC warning in back branches
Дата
Msg-id YCnPwuJb3dfNJTPt@paquier.xyz
обсуждение исходный текст
Ответ на GCC warning in back branches  (Thomas Munro <thomas.munro@gmail.com>)
Ответы Re: GCC warning in back branches  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: GCC warning in back branches  (Thomas Munro <thomas.munro@gmail.com>)
Список pgsql-hackers
On Mon, Feb 15, 2021 at 02:15:51PM +1300, Thomas Munro wrote:
> guc.c: In function ‘RestoreGUCState’:
> guc.c:9455:4: error: ‘varsourceline’ may be used uninitialized in this
> function [-Werror=maybe-uninitialized]
>  9455 |    set_config_sourcefile(varname, varsourcefile, varsourceline);
>       |    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> I propose the attached.

We usually don't bother much about compilation warnings in stable
branches as long as they are not real bugs, and these are the oldest
stable ones.  So why here?  I would have patched the top of the
function if it were me, btw.
--
Michael

Вложения

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

Предыдущее
От: Thomas Munro
Дата:
Сообщение: Re: shared tempfile was not removed on statement_timeout
Следующее
От: Tom Lane
Дата:
Сообщение: Re: GCC warning in back branches