a litter question about mdunlinkfiletag function

From: px shi <spxlyy123(at)gmail(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: a litter question about mdunlinkfiletag function
Date: 2024-09-30 02:43:17
Message-ID: CAAccyYKeYNUCRR8JQ_wvWLF1Fu9CM5FMXQqtW96gFLH43phRHg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

*Hi, hackers*

*When calculating the path, *forknum* is hardcoded as *MAIN_FORKNUM*:*
/* Compute the path. */
p = relpathperm(ftag->rnode, MAIN_FORKNUM);

*But since the *ftag* structure already contains *forknum*:*
typedef struct FileTag
{
int16 handler; /* SyncRequestHandler value, saving space */
int16 forknum; /* ForkNumber, saving space */
RelFileNode rnode;
uint32 segno;
} FileTag;

*Wouldn’t it be more flexible to use the value from the *ftag* structure
directly?*

*Best regards, *

*Pixian Shi*

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fujii Masao 2024-09-30 03:26:56 Re: May be BUG. Periodic burst growth of the checkpoint_req counter on replica.
Previous Message Peter Eisentraut 2024-09-30 02:09:22 Re: Virtual generated columns