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

Re: SEGV in contrib/array/array_iterator.c

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Matt Peterson <matt(at)caldera(dot)com>
Cc: dz(at)cs(dot)unitn(dot)it, pgsql-bugs(at)postgresql(dot)org
Subject: Re: SEGV in contrib/array/array_iterator.c
Date: 2002-04-02 18:29:27
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-bugs
Matt Peterson <matt(at)caldera(dot)com> writes:

> +     if(value == 0)
> +     {
> +         /* elog(NOTICE, "array_iterator: value is null"); */
> +               return (0);
> +     }

This patch is certainly wrong, as it will break array_iterator for
non-pointer datatypes (no, I do not believe your assertion to the

More to the point, inserting explicit tests for null is an obsolete
approach; the preferred way to do things these days is to mark the SQL
declarations of such functions with "isStrict".  Would you instead
update contrib/array to rely on isStrict?

It'd be even nicer to update contrib/array to V1 calling conventions,
but unless you are hitting 64-bit porting problems that may not do
anything useful for you...

			regards, tom lane

In response to


pgsql-bugs by date

Next:From: Stephan SzaboDate: 2002-04-02 20:05:48
Subject: Re: SEGV in contrib/array/array_iterator.c
Previous:From: Joe PiscitellaDate: 2002-04-01 21:42:08
Subject: Solaris 8 install of postgres 7.2

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