The following bug has been logged on the website:
Bug reference: 16921
Logged by: Geo Sil
Email address: rekgrpth(at)gmail(dot)com
PostgreSQL version: 13.2
Operating system: ubuntu
Description:
Is there a small memory leak here?
file: postgres/src/pl/plpgsql/src/pl_handler.c
function: plpgsql_extra_checks_check_hook
code: myextra = (int *) malloc(sizeof(int));
I don't find freeing memory.
But I suggest do it in functions plpgsql_extra_warnings_assign_hook and
plpgsql_extra_errors_assign_hook