aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2019-04-15 19:32:36 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2019-04-15 19:32:44 -0400
commitdde7fb7836c7428f79cb3cd88ca5febb802e767e (patch)
treee8630c4bddf646df25b609d53525c44f93c351dc
parentdbb984128ebf6b4bd6f12b4579ee9103ef1ca749 (diff)
downloadpostgresql-dde7fb7836c7428f79cb3cd88ca5febb802e767e.tar.gz
postgresql-dde7fb7836c7428f79cb3cd88ca5febb802e767e.zip
Use [FLEXIBLE_ARRAY_MEMBER] not [1] in MultiSortSupportData.
This struct seems to have not gotten the word about preferred coding style for variable-length arrays.
-rw-r--r--src/include/statistics/extended_stats_internal.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/include/statistics/extended_stats_internal.h b/src/include/statistics/extended_stats_internal.h
index 9fc591261eb..cc36176b3c5 100644
--- a/src/include/statistics/extended_stats_internal.h
+++ b/src/include/statistics/extended_stats_internal.h
@@ -43,8 +43,9 @@ typedef struct DimensionInfo
/* multi-sort */
typedef struct MultiSortSupportData
{
- int ndims; /* number of dimensions supported by the */
- SortSupportData ssup[1]; /* sort support data for each dimension */
+ int ndims; /* number of dimensions */
+ /* sort support data for each dimension: */
+ SortSupportData ssup[FLEXIBLE_ARRAY_MEMBER];
} MultiSortSupportData;
typedef MultiSortSupportData *MultiSortSupport;