Fix code comment in postgres_fdw.c

Started by Koshi Shibagaki (Fujitsu)almost 3 years ago2 messages
#1Koshi Shibagaki (Fujitsu)
shibagaki.koshi@fujitsu.com
1 attachment(s)

Hi Hackers,

This Koshi Shibagaki.
I found out that there is a mistake written in contrib/postgres_fdw/postgres_fdw.c.

Patch file is attached.

The non-existent function name " ExecCheckRTEPerms " was written in
the comment in postgresBeginForeignScan.
This mistake is considered to have occurred at commit ID: a61b1f74.
The function name was changed to "ExecCheckPermissions" and comments
related to this change was fixed,
however only the comment in postgresBeginForeignScan was not fixed.

Best

-----------------------------------------------
Fujitsu Limited
Koshi Shibagaki
shibagaki.koshi@fujitsu.com

Attachments:

fix_comment_in_fdw.patchapplication/octet-stream; name=fix_comment_in_fdw.patchDownload
diff --git a/contrib/postgres_fdw/postgres_fdw.c b/contrib/postgres_fdw/postgres_fdw.c
index f5926ab89df..d728bd70b31 100644
--- a/contrib/postgres_fdw/postgres_fdw.c
+++ b/contrib/postgres_fdw/postgres_fdw.c
@@ -1511,7 +1511,7 @@ postgresBeginForeignScan(ForeignScanState *node, int eflags)
 
 	/*
 	 * Identify which user to do the remote access as.  This should match what
-	 * ExecCheckRTEPerms() does.
+	 * ExecCheckPermissions() does.
 	 */
 	userid = OidIsValid(fsplan->checkAsUser) ? fsplan->checkAsUser : GetUserId();
 	if (fsplan->scan.scanrelid > 0)
#2Daniel Gustafsson
daniel@yesql.se
In reply to: Koshi Shibagaki (Fujitsu) (#1)
Re: Fix code comment in postgres_fdw.c

On 5 Apr 2023, at 07:27, Koshi Shibagaki (Fujitsu) <shibagaki.koshi@fujitsu.com> wrote:

I found out that there is a mistake written in contrib/postgres_fdw/postgres_fdw.c.

Thanks for the report, fixed.

--
Daniel Gustafsson