Re: ECPG Refactor: move sqlca variable in ecpg_log()

From: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
To: "Yuto Sasaki (Fujitsu)" <sasaki(dot)yuto-00(at)fujitsu(dot)com>
Cc: "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: ECPG Refactor: move sqlca variable in ecpg_log()
Date: 2024-10-10 16:13:18
Message-ID: 202410101613.dvquuowwuceh@alvherre.pgsql
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2024-Oct-10, Yuto Sasaki (Fujitsu) wrote:

> The sqlca variable in the ecpg_log() was declared with an unnecessarily wide
> scope, so I moved to the appropriate place.

Hmm, I'm not sure we want that, because if we do this, then
ECPGget_sqlca() gets run with the debug_mutex held. In the original
coding, it's run without the mutex.

--
Álvaro Herrera Breisgau, Deutschland — https://www.EnterpriseDB.com/
Voy a acabar con todos los humanos / con los humanos yo acabaré
voy a acabar con todos (bis) / con todos los humanos acabaré ¡acabaré! (Bender)

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2024-10-10 16:38:36 Re: overflow bug for inhcounts
Previous Message Tom Lane 2024-10-10 16:12:20 Re: Converting tab-complete.c's else-if chain to a switch