Re: [HACKERS] Typo in sequence.c

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Vinayak Pokale <vinpokale(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: [HACKERS] Typo in sequence.c
Date: 2023-11-23 04:41:56
Message-ID: ZV7YFMkc83qgKiEa@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jan 15, 2016 at 01:18:03PM +0900, Vinayak Pokale wrote:
> Hi,
>
> I found a typo in sequence.c
> Please check the attached patch.

I am not sure how to put this, but the typos are still there seven years
after you reported it, so fixed in master.

---------------------------------------------------------------------------

> diff --git a/src/backend/commands/sequence.c b/src/backend/commands/sequence.c
> index c98f981..25c57f6 100644
> --- a/src/backend/commands/sequence.c
> +++ b/src/backend/commands/sequence.c
> @@ -433,7 +433,7 @@ AlterSequence(AlterSeqStmt *stmt)
> aclcheck_error(ACLCHECK_NOT_OWNER, ACL_KIND_CLASS,
> stmt->sequence->relname);
>
> - /* lock page' buffer and read tuple into new sequence structure */
> + /* lock page buffer and read tuple into new sequence structure */
> seq = read_seq_tuple(elm, seqrel, &buf, &seqtuple);
>
> /* Copy old values of options into workspace */
> @@ -582,7 +582,7 @@ nextval_internal(Oid relid)
> return elm->last;
> }
>
> - /* lock page' buffer and read tuple */
> + /* lock page buffer and read tuple */
> seq = read_seq_tuple(elm, seqrel, &buf, &seqtuple);
> page = BufferGetPage(buf);
>
> @@ -876,7 +876,7 @@ do_setval(Oid relid, int64 next, bool iscalled)
> */
> PreventCommandIfParallelMode("setval()");
>
> - /* lock page' buffer and read tuple */
> + /* lock page buffer and read tuple */
> seq = read_seq_tuple(elm, seqrel, &buf, &seqtuple);
>
> if ((next < seq->min_value) || (next > seq->max_value))

>
> --
> Sent via pgsql-hackers mailing list (pgsql-hackers(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-hackers

--
Bruce Momjian <bruce(at)momjian(dot)us> https://momjian.us
EDB https://enterprisedb.com

Only you can decide what is important to you.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message jiye 2023-11-23 04:55:43 confusion about Re: Write operations in parallel mode's update part.
Previous Message Bharath Rupireddy 2023-11-23 04:40:46 Re: Lockless exit path for ReplicationOriginExitCleanup