Skip to content

Commit c0ef456

Browse files
committed
Volatile-ize some plperl variables that must survive into PG_CATCH blocks.
This appears to be necessary to fix a failure seen on buildfarm member sittella. It shouldn't be necessary according to the letter of the C standard, because we don't change the values of these variables within the PG_TRY blocks; but somehow gcc 4.7.2 is dropping the ball. Discussion: https://postgr.es/m/17555.1485179975@sss.pgh.pa.us
1 parent 366d2a3 commit c0ef456

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/pl/plperl/plperl.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1763,8 +1763,8 @@ Datum
17631763
plperl_call_handler(PG_FUNCTION_ARGS)
17641764
{
17651765
Datum retval;
1766-
plperl_call_data *save_call_data = current_call_data;
1767-
plperl_interp_desc *oldinterp = plperl_active_interp;
1766+
plperl_call_data *volatile save_call_data = current_call_data;
1767+
plperl_interp_desc *volatile oldinterp = plperl_active_interp;
17681768
plperl_call_data this_call_data;
17691769

17701770
/* Initialize current-call status record */
@@ -1813,8 +1813,8 @@ plperl_inline_handler(PG_FUNCTION_ARGS)
18131813
FunctionCallInfoData fake_fcinfo;
18141814
FmgrInfo flinfo;
18151815
plperl_proc_desc desc;
1816-
plperl_call_data *save_call_data = current_call_data;
1817-
plperl_interp_desc *oldinterp = plperl_active_interp;
1816+
plperl_call_data *volatile save_call_data = current_call_data;
1817+
plperl_interp_desc *volatile oldinterp = plperl_active_interp;
18181818
plperl_call_data this_call_data;
18191819
ErrorContextCallback pl_error_context;
18201820

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy