diff options
author | Itagaki Takahiro <itagaki.takahiro@gmail.com> | 2010-02-24 05:20:49 +0000 |
---|---|---|
committer | Itagaki Takahiro <itagaki.takahiro@gmail.com> | 2010-02-24 05:20:49 +0000 |
commit | 912eb88c7d2511086cb6f5257b788d8944d7344f (patch) | |
tree | 0a8319d023a288475d8e70285d5ad70c88ad00c4 | |
parent | 7bfd95a4a2d2016e213461401718ba7cd813ed50 (diff) | |
download | postgresql-912eb88c7d2511086cb6f5257b788d8944d7344f.tar.gz postgresql-912eb88c7d2511086cb6f5257b788d8944d7344f.zip |
Remove useless codes to initialize TupleDesc from dblink_exec.
-rw-r--r-- | contrib/dblink/dblink.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/contrib/dblink/dblink.c b/contrib/dblink/dblink.c index bb19abb965e..f9dfba8da6b 100644 --- a/contrib/dblink/dblink.c +++ b/contrib/dblink/dblink.c @@ -8,7 +8,7 @@ * Darko Prenosil <Darko.Prenosil@finteh.hr> * Shridhar Daithankar <shridhar_daithankar@persistent.co.in> * - * $PostgreSQL: pgsql/contrib/dblink/dblink.c,v 1.89 2010/02/14 18:42:11 rhaas Exp $ + * $PostgreSQL: pgsql/contrib/dblink/dblink.c,v 1.90 2010/02/24 05:20:49 itagaki Exp $ * Copyright (c) 2001-2010, PostgreSQL Global Development Group * ALL RIGHTS RESERVED; * @@ -1017,7 +1017,6 @@ dblink_exec(PG_FUNCTION_ARGS) char *msg; PGresult *res = NULL; text *sql_cmd_status = NULL; - TupleDesc tupdesc = NULL; PGconn *conn = NULL; char *connstr = NULL; char *sql = NULL; @@ -1070,11 +1069,6 @@ dblink_exec(PG_FUNCTION_ARGS) { dblink_res_error(conname, res, "could not execute command", fail); - /* need a tuple descriptor representing one TEXT column */ - tupdesc = CreateTemplateTupleDesc(1, false); - TupleDescInitEntry(tupdesc, (AttrNumber) 1, "status", - TEXTOID, -1, 0); - /* * and save a copy of the command status string to return as our * result tuple @@ -1083,11 +1077,6 @@ dblink_exec(PG_FUNCTION_ARGS) } else if (PQresultStatus(res) == PGRES_COMMAND_OK) { - /* need a tuple descriptor representing one TEXT column */ - tupdesc = CreateTemplateTupleDesc(1, false); - TupleDescInitEntry(tupdesc, (AttrNumber) 1, "status", - TEXTOID, -1, 0); - /* * and save a copy of the command status string to return as our * result tuple |