public inbox for [email protected]  
help / color / mirror / Atom feed
From: jinbinge <[email protected]>
To: [email protected]
Subject: A minor grammar error was found in a comment in the smgrtruncate function
Date: Tue, 20 Jan 2026 11:50:33 +0800 (CST)
Message-ID: <[email protected]> (raw)

Hi, 


I found a minor grammar error in a comment in the smgrtruncate function (src/backend/storage/smgr/smgr.c).
The word "is" is redundant and should be omitted.


/* Make the cached size is invalid if we encounter an error. */
reln->smgr_cached_nblocks[forknum[i]] = InvalidBlockNumber;




Regards,
Jinbinge




Attachments:

  [application/octet-stream] v1-0001-Fix-a-grammar-error-in-a-comment-in-smgrtruncate.patch (1.1K, ../[email protected]/3-v1-0001-Fix-a-grammar-error-in-a-comment-in-smgrtruncate.patch)
  download | inline diff:
From 69e107a6db9c8b2bc086ebf56a5369d324160432 Mon Sep 17 00:00:00 2001
From: jinbinge <[email protected]>
Date: Mon, 19 Jan 2026 22:28:54 -0500
Subject: [PATCH v1] Fix a grammar error in a comment in smgrtruncate().

A minor grammar error was found in a comment in the smgrtruncate function
(src/backend/storage/smgr/smgr.c). The word "is" is redundant and should be omitted.

Author: jinbinge <[email protected]>
---
 src/backend/storage/smgr/smgr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/backend/storage/smgr/smgr.c b/src/backend/storage/smgr/smgr.c
index 378c2a0..5391640 100644
--- a/src/backend/storage/smgr/smgr.c
+++ b/src/backend/storage/smgr/smgr.c
@@ -898,7 +898,7 @@ smgrtruncate(SMgrRelation reln, ForkNumber *forknum, int nforks,
 	/* Do the truncation */
 	for (i = 0; i < nforks; i++)
 	{
-		/* Make the cached size is invalid if we encounter an error. */
+		/* Make the cached size invalid if we encounter an error. */
 		reln->smgr_cached_nblocks[forknum[i]] = InvalidBlockNumber;
 
 		smgrsw[reln->smgr_which].smgr_truncate(reln, forknum[i],
-- 
1.8.3.1



view thread (2+ messages)

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected]
  Subject: Re: A minor grammar error was found in a comment in the smgrtruncate function
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox