Fix typos in ExecChooseHashTableSize()

From: Tender Wang <tndrwang(at)gmail(dot)com>
To: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Fix typos in ExecChooseHashTableSize()
Date: 2025-11-18 09:29:39
Message-ID: CAHewXNnzFjAjYLTkP78HE2PQ17MjBqFdQQg+0X6Wo7YMUb68xA@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

While stepping into the ExecChooseHashTableSize(),
I found two typos in the comments
One is as follows:
/* Check that buckets wont't overflow MaxAllocSize */
if (nbuckets > (MaxAllocSize / sizeof(HashJoinTuple) / 2))
break;

The other one is :

/*
* Check that space_allowed won't overlow SIZE_MAX.
*
* We don't use hash_table_bytes here, because it does not include the
* skew buckets. And we want to limit the overall memory limit.
*/
if ((*space_allowed) > (SIZE_MAX / 2))
break;

In the first comment, "wont't" should be "won't".
In the second comment, "overlow" should be "overflow".
The attached patch fixes these typos.
--
Thanks,
Tender Wang

Attachment Content-Type Size
0001-Fix-typos-in-the-comment.patch application/octet-stream 1.2 KB

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2025-11-18 09:29:54 Re: Issue with logical replication slot during switchover
Previous Message Daniel Gustafsson 2025-11-18 09:11:04 Re: Running a single test