Re: BUG #17514: Application with embedded SQL crashes when executing EXEC SQL PREPARE
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: okano.naoki@jp.fujitsu.com
Cc: pgsql-bugs@lists.postgresql.org
Date: 2022-06-09T17:01:36Z
Lists: pgsql-bugs
Attachments
- ensure-TSD-key-is-valid-before-use.patch (text/x-diff) patch
PG Bug reporting form <noreply@postgresql.org> writes: > Application with embedded SQL crashes with segmentation fault if I execute > EXEC SQL PREPARE > command before executing EXEC SQL CONNECT command (*1). > I know that it is the correct operation to execute EXEC SQL CONNECT command > first > and then execute EXEC SQL PREPARE command. > But I expect this wrong operation to result in an error, not a crash. We could do something like the attached, perhaps. Having said that, an application that includes no error checks is pretty unlikely to fail gracefully :-(. regards, tom lane
Commits
-
Avoid ecpglib core dump with out-of-order operations.
- f7797747fc8f 11.17 landed
- ba412c905af1 15.0 landed
- 9a3aab0f2a5b 12.12 landed
- 86258f083aad 10.22 landed
- 7bc21ed8c8e7 14.5 landed
- 12b8fb34a933 13.8 landed