Re: HAVE_WORKING_LINK still needed?

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: HAVE_WORKING_LINK still needed?
Дата
Msg-id 20200228150323.GA30707@alvherre.pgsql
обсуждение исходный текст
Ответ на HAVE_WORKING_LINK still needed?  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
Список pgsql-hackers
On 2020-Feb-28, Peter Eisentraut wrote:

> @@ -788,7 +788,6 @@ durable_link_or_rename(const char *oldfile, const char *newfile, int elevel)
>      if (fsync_fname_ext(oldfile, false, false, elevel) != 0)
>          return -1;
>  
> -#ifdef HAVE_WORKING_LINK
>      if (link(oldfile, newfile) < 0)
>      {
>          ereport(elevel,
> @@ -798,17 +797,6 @@ durable_link_or_rename(const char *oldfile, const char *newfile, int elevel)
>          return -1;
>      }
>      unlink(oldfile);
> -#else
> -    /* XXX: Add racy file existence check? */
> -    if (rename(oldfile, newfile) < 0)

Maybe rename durable_link_or_rename to just durable_link?

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



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

Предыдущее
От: Masahiko Sawada
Дата:
Сообщение: Re: Resume vacuum and autovacuum from interruption and cancellation
Следующее
От: legrand legrand
Дата:
Сообщение: Re: Planning counters in pg_stat_statements (using pgss_store)