Re: pg_check_dir comments and implementation mismatch
От
Tom Lane
Тема
Re: pg_check_dir comments and implementation mismatch
Дата
Msg-id
10495.1422553769@sss.pgh.pa.us
Ответ на
Re: pg_check_dir comments and implementation mismatch (Robert Haas)
Список
Дерево обсуждения
pg_check_dir comments and implementation mismatch Marco Nenciarini <marco.nenciarini@2ndquadrant.it>
Re: pg_check_dir comments and implementation mismatch Robert Haas <robertmhaas@gmail.com>
Re: pg_check_dir comments and implementation mismatch Tom Lane <tgl@sss.pgh.pa.us>
Re: pg_check_dir comments and implementation mismatch Michael Paquier <michael.paquier@gmail.com>
Re: pg_check_dir comments and implementation mismatch Marco Nenciarini <marco.nenciarini@2ndquadrant.it>
Re: pg_check_dir comments and implementation mismatch Robert Haas <robertmhaas@gmail.com>
Re: pg_check_dir comments and implementation mismatch Noah Misch <noah@leadboat.com>
Re: pg_check_dir comments and implementation mismatch Robert Haas <robertmhaas@gmail.com>
Re: pg_check_dir comments and implementation mismatch Tom Lane <tgl@sss.pgh.pa.us>
Re: pg_check_dir comments and implementation mismatch Noah Misch <noah@leadboat.com>
Re: pg_check_dir comments and implementation mismatch Marco Nenciarini <marco.nenciarini@2ndquadrant.it>
Re: pg_check_dir comments and implementation mismatch Robert Haas <robertmhaas@gmail.com>
Re: pg_check_dir comments and implementation mismatch Marco Nenciarini <marco.nenciarini@2ndquadrant.it>
Robert Haas writes: > On Thu, Jan 29, 2015 at 11:00 AM, Marco Nenciarini > wrote: >> reading pgcheckdir.c code I noticed that the function comment >> was outdated. The code now can return values from 0 to 4 while the >> comment explains only values 0,1,2. > This is not just a comment fix; you are clearly changing the behavior > of the function in some way. I think he's trying to fix a bug in terms of slipshod definition of the non-empty-directory subcases, but it would be nice to have some clarity about that. There is at least one other bug in that function now that I look at it: in event of a readdir() failure, it neglects to execute closedir(). Perhaps not too significant since all existing callers will just exit() anyway after a failure, but still ... regards, tom lane
В списке pgsql-hackers по дате отправления