Palloc library - Mailing list pgsql-general

From Konstantinos Vassiliadis
Subject Palloc library
Date
Msg-id Pine.LNX.3.95.980710193158.15982E-100000@p03.cs.man.ac.uk
Whole thread Raw
List pgsql-general
Hi,
I wrote a user-defined function and inside the source make use of palloc.
Somebody from the novice mailing list told me that the "palloc" source is
included in libpq and therefore I have included "libpq-fe.h" as the
documentation says. The program compiled fine.
However, today I read in the FAQ Section 4.2 :
 When writing user-defined functions, do not include the file
"libpq-fe.h". Doing so will cause your palloc to be a malloc instead of a
free.
Which one is right?

Kostas Vassiliadis



pgsql-general by date:

Previous
From: Konstantinos Vassiliadis
Date:
Subject: Defining 'C' functions in Postgres
Next
From: "Jackson, DeJuan"
Date:
Subject: RE: [GENERAL] How to rename a database?