mirror of
https://git.postgresql.org/git/postgresql.git
synced 2024-12-21 08:29:39 +08:00
Suppress volatile-related warning seen in some compilers.
Antique versions of gcc complain about vars that are initialized outside PG_TRY and then modified within it. Rather than marking the var volatile, expend one more line of code.
This commit is contained in:
parent
31c7c642b6
commit
1f115d98b9
@ -91,7 +91,7 @@ plpgsql_call_handler(PG_FUNCTION_ARGS)
|
|||||||
{
|
{
|
||||||
PLpgSQL_function *func;
|
PLpgSQL_function *func;
|
||||||
PLpgSQL_execstate *save_cur_estate;
|
PLpgSQL_execstate *save_cur_estate;
|
||||||
Datum retval = 0; /* make compiler happy */
|
Datum retval;
|
||||||
int rc;
|
int rc;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -119,8 +119,11 @@ plpgsql_call_handler(PG_FUNCTION_ARGS)
|
|||||||
retval = PointerGetDatum(plpgsql_exec_trigger(func,
|
retval = PointerGetDatum(plpgsql_exec_trigger(func,
|
||||||
(TriggerData *) fcinfo->context));
|
(TriggerData *) fcinfo->context));
|
||||||
else if (CALLED_AS_EVENT_TRIGGER(fcinfo))
|
else if (CALLED_AS_EVENT_TRIGGER(fcinfo))
|
||||||
|
{
|
||||||
plpgsql_exec_event_trigger(func,
|
plpgsql_exec_event_trigger(func,
|
||||||
(EventTriggerData *) fcinfo->context);
|
(EventTriggerData *) fcinfo->context);
|
||||||
|
retval = (Datum) 0;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
retval = plpgsql_exec_function(func, fcinfo);
|
retval = plpgsql_exec_function(func, fcinfo);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user