From a40a546e47efb43e070ee4cfe89ecf4b627ade64 Mon Sep 17 00:00:00 2001 From: "Vadim B. Mikheev" Date: Fri, 12 Sep 1997 06:57:04 +0000 Subject: [PATCH] RelationBuildRuleLock(): char* --> Datum for ruleaction and rule_evqual_string. --- src/backend/utils/cache/relcache.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/backend/utils/cache/relcache.c b/src/backend/utils/cache/relcache.c index 8369b81381..410355aa37 100644 --- a/src/backend/utils/cache/relcache.c +++ b/src/backend/utils/cache/relcache.c @@ -7,7 +7,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.23 1997/09/08 21:48:55 momjian Exp $ + * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.24 1997/09/12 06:57:04 vadim Exp $ * *------------------------------------------------------------------------- */ @@ -740,8 +740,8 @@ RelationBuildRuleLock(Relation relation) (Buffer *) NULL)) != NULL) { bool isnull; - char *ruleaction = NULL; - char *rule_evqual_string; + Datum ruleaction; + Datum rule_evqual_string; RewriteRule *rule; rule = (RewriteRule *) palloc(sizeof(RewriteRule)); @@ -770,11 +770,11 @@ RelationBuildRuleLock(Relation relation) Anum_pg_rewrite_ev_qual, pg_rewrite_tupdesc, &isnull); - ruleaction = textout((struct varlena *) ruleaction); - rule_evqual_string = textout((struct varlena *) rule_evqual_string); + ruleaction = PointerGetDatum (textout((struct varlena *) DatumGetPointer (ruleaction))); + rule_evqual_string = PointerGetDatum (textout((struct varlena *) DatumGetPointer (rule_evqual_string))); - rule->actions = (List *) stringToNode(ruleaction); - rule->qual = (Node *) stringToNode(rule_evqual_string); + rule->actions = (List *) stringToNode(DatumGetPointer (ruleaction)); + rule->qual = (Node *) stringToNode(DatumGetPointer (rule_evqual_string)); rules[numlocks++] = rule; if (numlocks == maxlocks) -- 2.40.0