Skip site navigation (1) Skip section navigation (2)

Re: user defined type

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Kjetil Haaland <kjetil(dot)haaland(at)student(dot)uib(dot)no>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: user defined type
Date: 2004-11-19 16:20:14
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-novice
Kjetil Haaland <kjetil(dot)haaland(at)student(dot)uib(dot)no> writes:
>    first = palloc(sizeof(char)*secondStart);
>    elog(NOTICE, "2:first=%s", first);
>    elog(NOTICE, "strlen(first)=%d", strlen(first));

This is bogus because you've only allocated space, not filled it with
anything.  It will contain whatever that RAM was last used for.

			regards, tom lane

In response to

pgsql-novice by date

Next:From: Brad RhineDate: 2004-11-19 16:35:10
Subject: PGSQL Config
Previous:From: Kjetil HaalandDate: 2004-11-19 16:07:34
Subject: Re: user defined type

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group