From 664908f5643f2d79f55cfb802ba55d7bce7e41ad Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Sat, 26 Feb 2000 06:36:44 +0000 Subject: [PATCH] Undo a couple of mistaken applications of NameStr() to StringInfos. It worked, because they both have fields named 'data', but it's surely trouble waiting to happen. I wonder whether there are more ... --- src/backend/rewrite/rewriteDefine.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/backend/rewrite/rewriteDefine.c b/src/backend/rewrite/rewriteDefine.c index a3ce8d2e8c..b8aea0400b 100644 --- a/src/backend/rewrite/rewriteDefine.c +++ b/src/backend/rewrite/rewriteDefine.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteDefine.c,v 1.42 2000/01/27 18:11:36 tgl Exp $ + * $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteDefine.c,v 1.43 2000/02/26 06:36:44 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -119,9 +119,9 @@ InsertRule(char *rulname, appendStringInfo(&rulebuf, "::text, '%s'::bool);", is_instead); - pg_exec_query_dest(NameStr(rulebuf), None, true); + pg_exec_query_dest(rulebuf.data, None, true); - pfree(NameStr(rulebuf)); + pfree(rulebuf.data); return LastOidProcessed; } -- 2.40.0