aboutsummaryrefslogtreecommitdiff
path: root/src/backend/parser
diff options
context:
space:
mode:
authorHeikki Linnakangas <heikki.linnakangas@iki.fi>2010-03-04 09:40:01 +0000
committerHeikki Linnakangas <heikki.linnakangas@iki.fi>2010-03-04 09:40:01 +0000
commitba8df78d9097365239b83befb9d1b1970f3ec15d (patch)
tree0bdaaddbd221e3bc29ff0fa48638d67c706ca80d /src/backend/parser
parentfe9a5f2f661370bf15a9dc059571c8ca9037aedc (diff)
downloadpostgresql-ba8df78d9097365239b83befb9d1b1970f3ec15d.tar.gz
postgresql-ba8df78d9097365239b83befb9d1b1970f3ec15d.zip
Fix IsBinaryCoercible to not confuse a cast using in/out functions
with binary compatibility. Backpatch to 8.4 where INOUT casts were introduced.
Diffstat (limited to 'src/backend/parser')
-rw-r--r--src/backend/parser/parse_coerce.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/backend/parser/parse_coerce.c b/src/backend/parser/parse_coerce.c
index 0aec4a850e2..6a627a7cbe1 100644
--- a/src/backend/parser/parse_coerce.c
+++ b/src/backend/parser/parse_coerce.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/parser/parse_coerce.c,v 2.177 2009/06/11 14:49:00 momjian Exp $
+ * $PostgreSQL: pgsql/src/backend/parser/parse_coerce.c,v 2.177.2.1 2010/03/04 09:40:01 heikki Exp $
*
*-------------------------------------------------------------------------
*/
@@ -1843,7 +1843,7 @@ IsBinaryCoercible(Oid srctype, Oid targettype)
return false; /* no cast */
castForm = (Form_pg_cast) GETSTRUCT(tuple);
- result = (castForm->castfunc == InvalidOid &&
+ result = (castForm->castmethod == COERCION_METHOD_BINARY &&
castForm->castcontext == COERCION_CODE_IMPLICIT);
ReleaseSysCache(tuple);