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

Re: pgsql: Add INET/CIDR operators: and, or, not, plus

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql: Add INET/CIDR operators: and, or, not, plus
Date: 2006-02-11 19:46:42
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-committers
Actually this patch has got some worse problems:

regression=# select ''::inet + 256;
(1 row)

which is wrong; if that's not obvious try

regression=# select (''::inet + 256) - 256;
(1 row)


regression=# select '127::2'::inet  - ('127::2'::inet - 256);
(1 row)

I think the overflow checks are wrong, and the current buildfarm
results say there's a portability problem too.  Working on it now...

			regards, tom lane

In response to

pgsql-committers by date

Next:From: Tom LaneDate: 2006-02-11 20:39:59
Subject: pgsql: Fix incorrect addition, subtraction, and overflow checking in new
Previous:From: Andrew DunstanDate: 2006-02-11 19:36:52
Subject: Re: [COMMITTERS] pgsql: Enable pg_ctl to give up admin

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