Re: Adding some error context for lock wait failures

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Zhang Mingli <zmlpostgres(at)gmail(dot)com>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org, Steve Baldwin <steve(dot)baldwin(at)gmail(dot)com>
Subject: Re: Adding some error context for lock wait failures
Date: 2025-07-11 02:53:28
Message-ID: 1664608.1752202408@sss.pgh.pa.us
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Zhang Mingli <zmlpostgres(at)gmail(dot)com> writes:
> Do we need to rollback error_context_stack to the previous state if we enter the branch for PG_CATCH()?

No. The PG_TRY mechanism itself deals with that: the next outer
level of PG_TRY will restore error_context_stack to what it had
been. If this were not so, most other places that add an
error_context_stack entry would also be broken.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Dilip Kumar 2025-07-11 03:13:05 Re: CHECKPOINT unlogged data
Previous Message sundayjiang (蒋浩天) 2025-07-11 02:46:13 回复:[Internet]Re: Re: 回复:Re: [PATCH] Pr event replacement of a function if it's used in an index expression and is not IMMUTABLE