Add a defense to prevent core dumps if 8.2 version of rank_cd() is used with
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 28 Dec 2006 01:09:04 +0000 (01:09 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 28 Dec 2006 01:09:04 +0000 (01:09 +0000)
commit32d029573d0b0908a18377959a835d7e17171fc2
tree1c7bd1060befcd30f88906577673538bc46b6e4e
parent46d90d6b52d92f4d7291ea05878ac4d07d08ae08
Add a defense to prevent core dumps if 8.2 version of rank_cd() is used with
the 8.1 SQL function definition for it.  Per report from Rajesh Kumar Mallah,
such a DBA error doesn't seem at all improbable, and the cost of checking for
it is not very high compared to the cost of running this function.  (It would
have been better to change the C name of the function so it wouldn't be called
by the old SQL definition, but it's too late for that now in the 8.2 branch.)
contrib/tsearch2/rank.c
src/include/catalog/pg_type.h