On Fri, Sep 29, 2017 at 2:19 PM, Kyotaro HORIGUCHI <horiguchi.kyot...@lab.ntt.co.jp> wrote: > It would practically work but I don't like the fact that the > patch relies on the specific directory/file ordering in the tar > stream. This is not about the CATVER directory but lower > directories. Being more strict, it actually makes excessive calls > to verify_dir_is_em..() for more lower directories contrarily to > expectations. > > I think that we can take more more robust way to detect the > CATVER directory. Just checking if it is a top-level directory > will work. That is, making the following change.
My tendency about this patch is still that it should be rejected. This is presenting additional handling for no real gain. > > - if (firstfile && !basetablespace) > + /* copybuf must contain at least one '/' here */ > + if (!basetablespace && strchr(copybuf, '/')[1] == 0) > > This condition exactly hits only CATVER directories not being > disturbed by file ordering of the tar stream. Anyway, as a new version is at least needed, I am marking it as returned with feedback. The CF is close to its end. -- Michael -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers