Re: [HACKERS] Cache Hash Index meta page.

Поиск
Список
Период
Сортировка
От Mithun Cy
Тема Re: [HACKERS] Cache Hash Index meta page.
Дата
Msg-id CAD__OujXhv6vLCEkxZx-Pi4Soo=eYaq9iuOEL8STnySOq5jsPA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: [HACKERS] Cache Hash Index meta page.  (Erik Rijkers <er@xs4all.nl>)
Ответы Re: [HACKERS] Cache Hash Index meta page.  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
On Tue, Feb 7, 2017 at 11:21 PM, Erik Rijkers <er@xs4all.nl> wrote:
> On 2017-02-07 18:41, Robert Haas wrote:
>>
>> Committed with some changes (which I noted in the commit message).

Thanks, Robert and all who have reviewed the patch and given their
valuable comments.

> This has caused a warning with gcc 6.20:
>
> hashpage.c: In function ‘_hash_getcachedmetap’:
> hashpage.c:1245:20: warning: ‘cache’ may be used uninitialized in this
> function [-Wmaybe-uninitialized]
>     rel->rd_amcache = cache;
>     ~~~~~~~~~~~~~~~~^~~~~~~

Yes, I also see the warning.  I think the compiler is not able to see
cache is always initialized and used under condition if
(rel->rd_amcache == NULL).
I think to make the compiler happy we can initialize the cache with
NULL when it is defined.

--
Thanks and Regards
Mithun C Y
EnterpriseDB: http://www.enterprisedb.com

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Вложения

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

Предыдущее
От: Corey Huinker
Дата:
Сообщение: Re: \if, \elseif, \else, \endif (was Re: [HACKERS] PSQL commands:\quit_if, \quit_unless)
Следующее
От: Robert Haas
Дата:
Сообщение: Re: [HACKERS] Cache Hash Index meta page.