Re: Setting visibility map in VACUUM's second phase

Поиск
Список
Период
Сортировка
От Pavan Deolasee
Тема Re: Setting visibility map in VACUUM's second phase
Дата
Msg-id CABOikdPLwop7pYX8hfsAurZyoG_kA0et33qG0MELBVFePUjx3w@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Setting visibility map in VACUUM's second phase  (Jeff Janes <jeff.janes@gmail.com>)
Ответы Re: Setting visibility map in VACUUM's second phase  (Heikki Linnakangas <hlinnakangas@vmware.com>)
Список pgsql-hackers
On Sun, Feb 3, 2013 at 2:31 AM, Jeff Janes <jeff.janes@gmail.com> wrote:

> Hi Pavan,
>
> I get this warning:
> vacuumlazy.c:890: warning: passing argument 6 of 'lazy_vacuum_page'
> makes pointer from integer without a cast
>
> and make check then fails.
>
> I've added '&' to that line, and it now passes make check with --enable-cassert.
>

Stupid me. Obviously I did not run make check before submitting the
patch, but I'm surprised my short pgbench test did not catch this.
Thanks a lot for finding and fixing this.

>
> At line 1096, when you release the vmbuffer, you don't set it to
> InvalidBuffer like the other places in the code do.  It seems like
> this does would lead to a crash or assertion failure, but it does not
> seem to do so.
>

That's harmless because vmbuffer is just a local variable in that
function and we are at the end of the function and that variable is
not used again. But it helps to just be consistent. So I'm OK with
your change.

>
> Also, the "Note: If you change anything below, also look at" should
> probably say "Note: If you change anything in the for loop below, also
> look at".  Otherwise I'd be wondering how far below the caveat
> applies.

Ok.

>
> I've attached a patch with these changes made.  Does this look OK?
>

Looks good to me. I also repeated pgbench and make check and they work
as expected. I'll add it to the CF and also mark the patch "ready for
committer"

Thanks,
Pavan

-- 
Pavan Deolasee
http://www.linkedin.com/in/pavandeolasee



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

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: PL/Python result object str handler
Следующее
От: Magnus Hagander
Дата:
Сообщение: Re: [PATCH] Add PQconninfoParseParams and PQconninfodefaultsMerge to libpq