Re: Problem with memory in C function - Mailing list pgsql-general

From Tom Lane
Subject Re: Problem with memory in C function
Date
Msg-id 749.1080355095@sss.pgh.pa.us
Whole thread Raw
In response to Problem with memory in C function  (Diogo Biazus <diogo@ikono.com.br>)
Responses Re: Problem with memory in C function
List pgsql-general
Diogo Biazus <diogo@ikono.com.br> writes:
> Am I doing something wrong?

You forgot to set up the length word that's required for a bytea value
(or any other variable-length datatype).  The system is taking the first
four bytes of the file data as the datum length.

            regards, tom lane

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Waiting for Commit
Next
From: Tom Lane
Date:
Subject: Re: Inserts get slower as table gets bigger