Re: small hstore bugfixes for 9.0 (w/patch)

From: Andrew Gierth <andrew(at)tao11(dot)riddles(dot)org(dot)uk>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: small hstore bugfixes for 9.0 (w/patch)
Date: 2010-09-16 03:38:54
Message-ID: 87sk1agy4e.fsf@news-spur.riddles.org.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

>>>>> "Tom" == Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> writes:

>> Two small fixes for hstore-new.
>> The hstore_compat one is arguable as to what is the best approach; the
>> assert that was there was just wrong, but I have been unable after
>> considerable searching to find any architectures that would fail the
>> check.

Tom> [ scratches head... ] It looks like that ought to be an
Tom> immediate core-dump for old data, given an assert-enabled build.
Tom> Are you saying it isn't? How?

The assert was just wrong, as I said. (Obviously it somehow escaped
testing; it's possible that I did my original tests on a non-asserts
build by mistake.)

What I meant to say is that I couldn't find any architectures that
would fail what the check _should have been_.

The reason for dropping the assert and doing the check in actual code
is because if any platform does exist where the check fails, you'd
just get corrupt results in a non-asserts build. I figured it was
better to produce an actual error instead.

--
Andrew.

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Andrew Gierth 2010-09-16 03:47:32 Re: small hstore bugfixes for 9.0 (w/patch)
Previous Message Tom Lane 2010-09-16 02:37:50 Re: small hstore bugfixes for 9.0 (w/patch)