I noticed that this function has a "namspace" parameter.  The attached
patch adds the missing 'e'.

-- 
nathan
>From 3f1431517cee250f1280adca739de0d6b9c77080 Mon Sep 17 00:00:00 2001
From: Nathan Bossart <nat...@postgresql.org>
Date: Tue, 5 Aug 2025 16:01:34 -0500
Subject: [PATCH v1 1/1] fix ancient typo in transformRelOptions()

---
 src/backend/access/common/reloptions.c | 10 +++++-----
 src/include/access/reloptions.h        |  2 +-
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/src/backend/access/common/reloptions.c 
b/src/backend/access/common/reloptions.c
index 594a657ea1a..852cd73f5da 100644
--- a/src/backend/access/common/reloptions.c
+++ b/src/backend/access/common/reloptions.c
@@ -1164,7 +1164,7 @@ add_local_string_reloption(local_relopts *relopts, const 
char *name,
  * but we declare them as Datums to avoid including array.h in reloptions.h.
  */
 Datum
-transformRelOptions(Datum oldOptions, List *defList, const char *namspace,
+transformRelOptions(Datum oldOptions, List *defList, const char *namespace,
                                        const char *const validnsps[], bool 
acceptOidsOff, bool isReset)
 {
        Datum           result;
@@ -1200,14 +1200,14 @@ transformRelOptions(Datum oldOptions, List *defList, 
const char *namspace,
                                int                     kw_len;
 
                                /* ignore if not in the same namespace */
-                               if (namspace == NULL)
+                               if (namespace == NULL)
                                {
                                        if (def->defnamespace != NULL)
                                                continue;
                                }
                                else if (def->defnamespace == NULL)
                                        continue;
-                               else if (strcmp(def->defnamespace, namspace) != 
0)
+                               else if (strcmp(def->defnamespace, namespace) 
!= 0)
                                        continue;
 
                                kw_len = strlen(def->defname);
@@ -1277,14 +1277,14 @@ transformRelOptions(Datum oldOptions, List *defList, 
const char *namspace,
                        }
 
                        /* ignore if not in the same namespace */
-                       if (namspace == NULL)
+                       if (namespace == NULL)
                        {
                                if (def->defnamespace != NULL)
                                        continue;
                        }
                        else if (def->defnamespace == NULL)
                                continue;
-                       else if (strcmp(def->defnamespace, namspace) != 0)
+                       else if (strcmp(def->defnamespace, namespace) != 0)
                                continue;
 
                        /*
diff --git a/src/include/access/reloptions.h b/src/include/access/reloptions.h
index dfbb4c85460..320f68ead8f 100644
--- a/src/include/access/reloptions.h
+++ b/src/include/access/reloptions.h
@@ -233,7 +233,7 @@ extern void add_local_string_reloption(local_relopts 
*relopts, const char *name,
                                                                           
fill_string_relopt filler, int offset);
 
 extern Datum transformRelOptions(Datum oldOptions, List *defList,
-                                                                const char 
*namspace, const char *const validnsps[],
+                                                                const char 
*namespace, const char *const validnsps[],
                                                                 bool 
acceptOidsOff, bool isReset);
 extern List *untransformRelOptions(Datum options);
 extern bytea *extractRelOptions(HeapTuple tuple, TupleDesc tupdesc,
-- 
2.39.5 (Apple Git-154)

Reply via email to