]> granicus.if.org Git - postgresql/commitdiff
Improve code comments
authorPeter Eisentraut <peter_e@gmx.net>
Sat, 14 Apr 2018 14:04:36 +0000 (10:04 -0400)
committerPeter Eisentraut <peter_e@gmx.net>
Sat, 14 Apr 2018 14:04:36 +0000 (10:04 -0400)
As of 0c2c81b403db420bfce36f168887db72932dbf09, the replication
parameter in libpq is no longer "deliberately undocumented".

src/backend/replication/libpqwalreceiver/libpqwalreceiver.c

index ec37377efe5b2501151fff39ae937e69fbbc9f47..e4d261bd79302febcbd18f4b9ba519a3ad92c4b4 100644 (file)
@@ -128,10 +128,7 @@ libpqrcv_connect(const char *conninfo, bool logical, const char *appname,
 
        /*
         * We use the expand_dbname parameter to process the connection string (or
-        * URI), and pass some extra options. The deliberately undocumented
-        * parameter "replication=true" makes it a replication connection. The
-        * database name is ignored by the server in replication mode, but specify
-        * "replication" for .pgpass lookup.
+        * URI), and pass some extra options.
         */
        keys[i] = "dbname";
        vals[i] = conninfo;
@@ -139,6 +136,10 @@ libpqrcv_connect(const char *conninfo, bool logical, const char *appname,
        vals[i] = logical ? "database" : "true";
        if (!logical)
        {
+               /*
+                * The database name is ignored by the server in replication mode, but
+                * specify "replication" for .pgpass lookup.
+                */
                keys[++i] = "dbname";
                vals[i] = "replication";
        }