postgres.git / summary / log / commit / refs
commit 2bbec7c49a6c872fdfdddf7ff9ea9dc9cebaef40
Author: Fujii Masao <fujii@postgresql.org>
Date: Fri Jul 10 11:36:36 2026 +0000
postgres_fdw: Mark statistics import helpers as static
The set_*_arg helper functions in postgres_fdw.c are declared
static, but their definitions omitted the static keyword. Add it to
make their file-local scope explicit and keep the declarations and
definitions consistent.
Also fix a couple of nearby comment typos.
This is a followup to commit 54cd6fc8317.
Author: Fujii Masao <masao.fujii@gmail.com>
Reviewed-by: Etsuro Fujita <etsuro.fujita@gmail.com>
Discussion: https://postgr.es/m/CAHGQGwGjcQ4SwHMUQ9P8UYQ7iLKL1QE3uLSdONToQ1MrzpUUoQ@mail.gmail.com
Backpatch-through: 19
contrib/postgres_fdw/postgres_fdw.c | 12 ++++++------
src/backend/statistics/attribute_stats.c | 2 +-
src/backend/statistics/relation_stats.c | 2 +-
3 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/contrib/postgres_fdw/postgres_fdw.c b/contrib/postgres_fdw/postgres_fdw.c
index e6e0a4ab9b5..70de942de12 100644
--- a/contrib/postgres_fdw/postgres_fdw.c
+++ b/contrib/postgres_fdw/postgres_fdw.c
@@ -6134,7 +6134,7 @@ import_fetched_statistics(Relation relation,
}
/*
- * Conenience routine to fetch the value for the row/column of the PGresult
+ * Convenience routine to fetch the value for the row/column of the PGresult
*/
static char *
get_opt_value(PGresult *res, int row, int col)
@@ -6147,7 +6147,7 @@ get_opt_value(PGresult *res, int row, int col)
/*
* Convenience routine for setting optional text arguments
*/
-void
+static void
set_text_arg(NullableDatum *arg, const char *s)
{
if (s)
@@ -6165,7 +6165,7 @@ set_text_arg(NullableDatum *arg, const char *s)
/*
* Convenience routine for setting optional int32 arguments
*/
-void
+static void
set_int32_arg(NullableDatum *arg, const char *s)
{
if (s)
@@ -6185,7 +6185,7 @@ set_int32_arg(NullableDatum *arg, const char *s)
/*
* Convenience routine for setting optional uint32 arguments
*/
-void
+static void
set_uint32_arg(NullableDatum *arg, const char *s)
{
if (s)
@@ -6205,7 +6205,7 @@ set_uint32_arg(NullableDatum *arg, const char *s)
/*
* Convenience routine for setting optional float arguments
*/
-void
+static void
set_float_arg(NullableDatum *arg, const char *s)
{
if (s)
@@ -6225,7 +6225,7 @@ set_float_arg(NullableDatum *arg, const char *s)
/*
* Convenience routine for setting optional float[] arguments
*/
-void
+static void
set_floatarr_arg(NullableDatum *arg, const char *s)
{
if (s)
diff --git a/src/backend/statistics/attribute_stats.c b/src/backend/statistics/attribute_stats.c
index 8e214fe60dc..c47df5adab3 100644
--- a/src/backend/statistics/attribute_stats.c
+++ b/src/backend/statistics/attribute_stats.c
@@ -707,7 +707,7 @@ pg_restore_attribute_stats(PG_FUNCTION_ARGS)
}
/*
- * Import attribute statistics from NullableDatum inputs for all statitical
+ * Import attribute statistics from NullableDatum inputs for all statistical
* values.
*
* For now, the 'version' argument is ignored. In the future it can be used
diff --git a/src/backend/statistics/relation_stats.c b/src/backend/statistics/relation_stats.c
index 990a7511d04..fbaab92284f 100644
--- a/src/backend/statistics/relation_stats.c
+++ b/src/backend/statistics/relation_stats.c
@@ -256,7 +256,7 @@ pg_restore_relation_stats(PG_FUNCTION_ARGS)
}
/*
- * Import relation statistics from NullableDatum inputs for all statitical
+ * Import relation statistics from NullableDatum inputs for all statistical
* values.
*
* For now, the 'version' argument is ignored. In the future it can be used
[parent: 5b5e99047ab0]