]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
postgres_fdw: Mark statistics import helpers as static
authorFujii Masao <fujii@postgresql.org>
Fri, 10 Jul 2026 11:36:36 +0000 (20:36 +0900)
committerFujii Masao <fujii@postgresql.org>
Fri, 10 Jul 2026 11:37:38 +0000 (20:37 +0900)
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
src/backend/statistics/attribute_stats.c
src/backend/statistics/relation_stats.c

index e6e0a4ab9b5a03691387ed7b20884fa517cf07a3..70de942de1217ea5498120761e8414e7db0142c8 100644 (file)
@@ -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)
index 8e214fe60dc0623b01711773e60ce9e4fca4c549..c47df5adab3f17076ee113df753076efebaa15b8 100644 (file)
@@ -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
index 990a7511d040957e19d6cab7c9cdb72c871fb02a..fbaab92284fa3803df3ef5b008035abdbfd0912a 100644 (file)
@@ -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