From: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-committers(at)lists(dot)postgresql(dot)org |
Subject: | Re: pgsql: Redesign initialization of partition routing structures |
Date: | 2018-11-16 19:54:03 |
Message-ID: | 20181116195403.s3q4o7xg3sjfmqmk@alvherre.pgsql |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
On 2018-Nov-16, Tom Lane wrote:
> Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> writes:
> > Redesign initialization of partition routing structures
>
> Some of the buildfarm doesn't like this:
>
> ccache gcc -std=c99 -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -Wmissing-format-attribute -Wformat-security -fno-strict-aliasing -fwrapv -g -O2 -I../../../src/include -isysroot /Developer/SDKs/MacOSX10.6.sdk -DCOPY_PARSE_PLAN_TREES -DRAW_EXPRESSION_COVERAGE_TEST -c -o functioncmds.o functioncmds.c
> execPartition.c:96: error: redefinition of typedef 'PartitionTupleRouting'
> ../../../src/include/executor/execPartition.h:23: error: previous declaration of 'PartitionTupleRouting' was here
> make[3]: *** [execPartition.o] Error 1
Thanks, I just noticed it and will push this in a minute. Since I
cannot reproduce the error, it's a blind fix, but seems correct.
diff --git a/src/backend/executor/execPartition.c b/src/backend/executor/execPartition.c
index e3cb4fb1be..ec5628c9c2 100644
--- a/src/backend/executor/execPartition.c
+++ b/src/backend/executor/execPartition.c
@@ -82,7 +82,7 @@
* Memory context used to allocate subsidiary structs.
*-----------------------
*/
-typedef struct PartitionTupleRouting
+struct PartitionTupleRouting
{
Relation partition_root;
PartitionDispatch *partition_dispatch_info;
@@ -93,7 +93,7 @@ typedef struct PartitionTupleRouting
int max_partitions;
HTAB *subplan_resultrel_htab;
MemoryContext memcxt;
-} PartitionTupleRouting;
+};
/*-----------------------
* PartitionDispatch - information about one partitioned table in a partition
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Alvaro Herrera | 2018-11-16 19:56:43 | pgsql: Avoid re-typedef'ing PartitionTupleRouting |
Previous Message | Alvaro Herrera | 2018-11-16 19:35:58 | pgsql: pgbench: introduce a RandomState struct |