From: Nathan Bossart Date: Wed, 12 Feb 2025 21:45:40 +0000 (-0600) Subject: Remove unneeded volatile qualifier in fmgr.c. X-Git-Url: http://git.postgresql.org/gitweb/?a=commitdiff_plain;h=9e66a2b7841a5c1f929103c82c73244d3f5f3416;p=users%2Frhaas%2Fpostgres.git Remove unneeded volatile qualifier in fmgr.c. Currently, the save_nestlevel variable in fmgr_security_definer() is marked volatile. While this may have been necessary when it was used in a PG_CATCH section (as explained in the comment for PG_TRY in elog.h), it appears to have been unnecessary since commit 82a47982f3, which removed its use in a PG_CATCH section. Author: Julien Rouhaud Reviewed-by: Bertrand Drouvot Discussion: https://postgr.es/m/Z6xbAgXKY2L-3d5Q%40jrouhaud --- diff --git a/src/backend/utils/fmgr/fmgr.c b/src/backend/utils/fmgr/fmgr.c index aa89ae8fe1..782291d999 100644 --- a/src/backend/utils/fmgr/fmgr.c +++ b/src/backend/utils/fmgr/fmgr.c @@ -639,7 +639,7 @@ fmgr_security_definer(PG_FUNCTION_ARGS) ListCell *lc1, *lc2, *lc3; - volatile int save_nestlevel; + int save_nestlevel; PgStat_FunctionCallUsage fcusage; if (!fcinfo->flinfo->fn_extra)