Re: failed assertion in toasting code - Mailing list pgsql-hackers

From Sergey E. Koposov
Subject Re: failed assertion in toasting code
Date
Msg-id Pine.LNX.4.64.0802201509480.28404@lnfm1.sai.msu.ru
Whole thread Raw
In response to Re: failed assertion in toasting code  (Gregory Stark <stark@enterprisedb.com>)
Responses Re: failed assertion in toasting code  (Gregory Stark <stark@enterprisedb.com>)
List pgsql-hackers
On Wed, 20 Feb 2008, Gregory Stark wrote:

> You aren't doing anything funny in the image_in function to generate
> compressed varlenas manually are you?

No, I don't. The only thing I do there is        unsigned char *in = PG_GETARG_CSTRING(0);//"AABBCCDDEE1122";//
and return the pointer to the palloced constructed standard varlena 
datum with

typedef struct
{        int4 length;        unsigned char data[1];
} image;
        image *im = (image *) palloc(VARHDRSZ + out_len);        memset(im, 0, VARHDRSZ + out_len);     im->length =
out_len+ VARHDRSZ;    /* fill the im->data    .......     */        PG_RETURN_POINTER(im);
 

Regards,    Sergey

*******************************************************************
Sergey E. Koposov
Max Planck Institute for Astronomy/Cambridge Institute for Astronomy/Sternberg Astronomical Institute
Tel: +49-6221-528-349
Web: http://lnfm1.sai.msu.ru/~math
E-mail: math@sai.msu.ru


pgsql-hackers by date:

Previous
From: Gregory Stark
Date:
Subject: Re: failed assertion in toasting code
Next
From: "Sergey E. Koposov"
Date:
Subject: Re: failed assertion in toasting code